News for hackers. Stuff that matters.
Re:Weekend projects: getting silly with C by 8372049 on Sunday June 30, 2024 @07:03AM (#40836494)
> if they didn’t use the syntax if (1==x) rather than if (x==1). The former will not compile if you accidentally use variable assignment instead of equality operator

No need for Yoda notation. clang will warn of this by default and gcc will do so if you compile with -Wall, which should also be your default.

There are no comments on this comment yet.