C's syntax
Olivier Dagenais
olivierS.dagenaisP at canadaA.comM
Mon Oct 23 08:25:33 EDT 2000
> It then follows that you can easily write
> foo *bar,baz;
> One pointer to a bar, one whole baz.
Case in point for Alex, that should be one pointer to a 'foo' and one whole
'foo' (whatever 'foo' currently is 'typedef'ed.) :p
> care if some newbie writes 'if (a=0)...' when they mean 'if (a==0)'
because
> I don't. Anyway, they should be writing 'if (!a) ...'
To get around this, we were taught to put the constant on the other side, so
that if we forgot an '=', we would get a compiler error:
if ( 0 = a ) /* is bad */
if ( 0 == a ) /* is good */
--
----------------------------------------------------------------------
Olivier A. Dagenais - Software Architect and Developer
"Someone called 'Type your name here' is impersonating me on the
internet and is posting exactly the same things I am posting!"
More information about the Python-list
mailing list