Path: utzoo!attcan!uunet!cs.utexas.edu!know!zaphod.mps.ohio-state.edu!lavaca.uh.edu!uhnix1!sugar!ficc!peter From: peter@ficc.ferranti.com (Peter da Silva) Newsgroups: comp.lang.misc Subject: := versus == (Re: He's not the only one at it again!) Message-ID: <=L-4T-A@ggpc2.ferranti.com> Date: 31 Jul 90 11:56:11 GMT References: <25630@cs.yale.edu> <58091@lanl.gov> <3478@goanna.cs.rmit.oz.au> <25681@cs.yale.edu> <1990Jul30.143530.24295@phri.nyu.edu> <25684@cs.yale.edu> Reply-To: peter@ficc.ferranti.com (Peter da Silva) Organization: Xenix Support, FICC Lines: 9 I think the best solution to this is to use ":=" for assignment and "==" for equality. That way there would be no problem with using the wrong one in the wrong context by accident. (aside: the reason = versus == comes up in C has nothing to do with mathematics or ease of typing, but because assignment is an *operator*, not a *statement*. There do exist languages where = is used for both purposes with no possibility of confusion, and in fact the old Berkeley Pascal compiler (pi) would turn = in an assignment context into := in a completely reliable manner) -- Peter da Silva. `-_-' +1 713 274 5180. 'U`