Hi Arkadi

Arkadi Shishlov schrieb:
> Is it possible to get a warning from the compiler for suspicious lines of 
> code like
> some_var == 123;
> that makes little sense.
> ?

Indeed!)

This one probably makes even less sense but also
passes without error (both GCC and SDCC:)


------8<------------------------------------------
void foo(){} int main( void )
{
     int i = foo?
     100:10;

     while( foo && i-- )
         1,2,3; 4;

     5;

     5 == 6;

     7 / 8 == 78;

     7/8 ? (79):
     90;

     "GCC 4.3.1 and SDCC 2.8.2 eat this"
     "without error" ;;; "to"
     "be more accurate: also without warning"

     "Don't we all like C" ? "No" : "No"; !"YES";

     return ~!!i?i==8:8%+8;-7;;
}
------>8------------------------------------------

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to