Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Useless bit of compiler optimizations trivia: the "this printf() is equivalent to puts()" optimization seems to work by looking for the '%' in the format string, not by counting whether there is only one argument to printf(), e.g. if you add 42 as a second argument to the printf() — which is absolutely legal and required by the standard to Work as Intended™ — the resulting binary still uses puts().


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: