3 ms·
It is useful to keep in mind a common confusion. Apple and various BSD's stopped updating GCC around version 4.2, the last GPLv2 version, which is approximatel
by cliffbean 15y ago
It is useful to keep in mind a common confusion.
Apple and various BSD's stopped updating GCC around version 4.2, the last GPLv2 version, which is approximately 4 years old now. For people who only develop on those platforms, this is what "GCC" means. So when someone from Apple or someone with an obvious BSD bias talks about how much better clang is than "GCC", they're usually talking about how much better clang is than an old unmaintained version of GCC.
clang does have strengths, but when we make comparisons, we should be clear about what it is we're comparing.
- nknight 15y agoUnless there's been a concerted effort in the last ~year or so to improve GCC's error messages and compilation speed, clang's primary technical strengths remain unchanged relative to GCC. Saying we're comparing old versions isn't really useful unless the new versions have actually addressed the relevant issues.
- cliffbean 15y agoRecent versions of GCC do, in fact, have improved error messages. For example, GCC 4.6 fixed a problem that the post I was replying to mentioned, where a missing semicolon after a struct definition would cause GCC to elicit an error message pointing to some other nearby line. If you're comparing clang to just GCC 4.2, then say that. If you've compared it with recent versions of GCC too, then say that.
- adbge 15y ago$ gcc -v ... gcc version 4.6.2 20120120 (prerelease) (GCC) When it comes to diagnostics, GCC isn't even competitive.