3 ms·
The author recommends -std=c99 (-pedantic) default flags, yet suggests K&R (2nd edition, presumably) as a reference...
by 174SIGSEGV 5y ago
The author recommends -std=c99 (-pedantic) default flags, yet suggests K&R (2nd edition, presumably) as a reference...
- pantalaimon 5y agoLittle reason to not use at least -std=c11 these days
- bierjunge 5y agoLinux is C99, most microcontrollers use C99 or even C89. It would be nice to get the new features, but it's not always possible.
- pantalaimon 5y ago> most microcontrollers use C99 or even C89 Most microcontrollers are ARM Cortex-M and are programmed with a recent GCC toolchain
- flohofwoe 5y agoMSVC has C11 support only since very, very recently: https://devblogs.microsoft.com/cppblog/c11-and-c17-standard-support-arriving-in-msvc/ https://devblogs.microsoft.com/cppblog/c11-and-c17-standard-... (it has a solid subset of C99 since around VS2015 though, just _Generic was missing - and ignoring VLAs, which have been "dropped" in later C standards anyway).
- junon 5y agoVerifiers haven't caught up to C11 yet.
- flohofwoe 5y agoAlso, why still use the old confusing long, short, long long etc... types when the much better fixed-width types had been standardized in stdint.h since C99 (even the Visual Studio C compiler has those since at least VS2015).