6 ms·
I guess they care too much about portability to use "pragma GCC poison"?
by jepler 7y ago
I guess they care too much about portability to use "pragma GCC poison"?
- zsrxx 7y agoWanting code to compile on something other than gcc is not "caring too much", it's being responsible
- The_rationalist 7y agoResponsible? What an hyperbolic statement. Could you enlighten me on what would be the significant negative consequences? I hope that your mental equation take into account the missed usefulness of GCC only attributes, flags and extensions by being clang compatible.
- zsrxx 7y agoI don't know what to tell you. Do you think all compilers should implement all GCC proprietary extensions, basically creating a parallel C standard? And that's not saying that GCC extensions are not useful, but they should not be considered the norm
- klez 7y agoAgreed. But I wonder if we already have a sort of parallel C standard already with POSIX (of course the parts about C, not about OS facilities).
- adrianN 7y agoFor this particular case it wouldn't be a big deal. The code is still valid C, it's just that GCC makes sure that you don't use the poisoned values.
- MaxBarraclough 7y agoTo rephrase adrianN's comment: It wouldn't mean breaking things on compilers other than GCC. It would simply add compile-time checks when building with GCC, and would do nothing on other compilers.