Semi constant expressions

Alan J Rosenthal flaps at dgp.toronto.edu
Sat Sep 2 01:19:29 AEST 1989


msb at sq.sq.com (Mark Brader) writes:
>>	x << (100000000L)
>By the way, the L on the right operand has no effect.  ...
>and the plain constant 100000000 would be [int] or [long] depending on the
>size of ints.

But a good compiler might warn you if you say "100000000" and it gets promoted
to long.  (For example, not that this compiler is otherwise good, later
versions of the QNX C compiler.)  Of course, compilers can warn about anything,
but this sounds like a reasonable warning.

ajr



More information about the Comp.std.c mailing list