Fantastic exchange from DConf
Guillaume Boucher via Digitalmars-d
digitalmars-d at puremagic.com
Tue May 9 16:09:27 PDT 2017
On Tuesday, 9 May 2017 at 16:55:54 UTC, H. S. Teoh wrote:
> Ouch. Haha, even I forgot about this particularly lovely
> aspect of C. Hooray, freely call functions without declaring
> them, and "obviously" they return int! Why not?
To be fair, most of your complaints can be fixed by enabling
compiler warnings and by avoiding the use of de-facto-deprecated
functions (strnlen). The remaining problems theoretically
shouldn't occur by disciplined use of commonly accepted C99
guidelines. But I agree that even then and with the use of
sanitizers writing correct C code remains very hard.
More information about the Digitalmars-d
mailing list