3 ms·
The clang integration was announced in 2015, so a full 16 years after C99 was finalised. A C compiler ignoring most of the spec for at least decade seems hugel
by shakna 10y ago
The clang integration was announced in 2015, so a full 16 years after C99 was finalised.
A C compiler ignoring most of the spec for at least decade seems hugely odd to me.
First and foremost, MSVC is a C compiler, and for a long time was the only one available.
Comparing it's spec support story with GCC, clang, tcc or turboc, and it stands out.
I mean, avr-gcc is designed mostly for use with C++, you're expected to use C++. But it still fully supports C99 and most of C11, with a goal to fix that in the next three years.
It's... Odd.
It may make sense if MS assumes all their developers have no need of the many C APIs they maintain, but it is certainly not the reasoning of many other compilers.
- pjmlp 10y ago> First and foremost, MSVC is a C compiler, and for a long time was the only one available. Since when? MSVC doesn't exist, never did, the product has always been called MSVC++. The only pure C compiler from Microsoft was called *Microsoft C Compiler", and Microsoft was actually the last C compiler vendor adding C++ support for MS-DOS. > Comparing it's spec support story with GCC, clang, tcc or turboc, and it stands out. GCC used to stand for GNU C Compiler, before it got renamed into GNU Compiler Collection. tcc is a C compiler. Turbo C was a C compiler, the C++ one was called Turbo C++. clang always supported C, C++ and Objective-C since the beginning, because C's subset of Objective-C is a 100% compatible with C, which isn't the case with C++. > t may make sense if MS assumes all their developers have no need of the many C APIs they maintain, but it is certainly not the reasoning of many other compilers. They have assumed this for a long time now, since 2012 actually, people seem to keep not paying attention. https://herbsutter.com/2012/05/03/reader-qa-what-about-vc-and-c99/ https://herbsutter.com/2012/05/03/reader-qa-what-about-vc-an...
- throwaway19182 10y agoC++ culture at its worst -- listen to the weekly recommendations of Herb, Scott et al. and you'll be fine. Trust us.
- pjmlp 10y agoC++ culture at its best, fixing C memory corruption and UB errors inflicted into the industry, while providing an upgrade path for saner coding.
- throwaway30101 10y agoThanks, now we know why Windows has such a stellar security record. Really, talking to C++ proponents is like talking to a wall. C programmers can at least admit failures, grumble about their tools and have diverse opinions. Not so in C++. Religious adherence to dogma, unwaivering allegiance to conference heroes, unbridled enthusiasm for every new feature seems to be a prerequisite for programming in that language. And God forbid that there's any self-criticism, ever.
- pjmlp 10y agoC developers don't even care about security, as shown by making the C99 security annex, which was pretty small actually, optional in C11. Or they just like to wave the amount of CVE exploits that get added daily to the database, as not being a language issue.
- throwaway10190 10y agoThis is not my experience at all. I've often observed C programmers that were visibly embarrassed if a single segfault -- let alone an exploit -- was found in their code. I've observed C++ programmers who were completely indifferent to segfaults, shipped 5 more releases with the bug and continued instead discussing their latest abstractions and how awesome and secure C++ is. Also, for yet another time: The majority of CVE-worthy programs is written in C (for good reasons), why don't you look at Windows instead?
- pjmlp 10y ago> why don't you look at Windows instead? Because GNU/Linux is even worse nowadays, in spite of joking how Windows used to be, somehow they forgot to follow suit in terms of security. "Unsafe at any clock speed: Linux kernel security needs a rethink" http://arstechnica.com/security/2016/09/linux-kernel-security-needs-fixing/ http://arstechnica.com/security/2016/09/linux-kernel-securit...