Re:Banned C standard library functions in Git source code
by jepler on Sunday August 25, 2019 @09:55AM
(#20792970)
I guess they care too much about portability to use "pragma GCC poison"?
[ Parent
| on HN ]
Re:Banned C standard library functions in Git source code
by MaxBarraclough on Sunday August 25, 2019 @12:10PM
(#20793724)
To 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.
Re:Banned C standard library functions in Git source code
by zsrxx on Sunday August 25, 2019 @10:25AM
(#20793125)
Wanting code to compile on something other than gcc is not "caring too much", it's being responsible
Re:Banned C standard library functions in Git source code
by adrianN on Sunday August 25, 2019 @10:43AM
(#20793260)
For 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.
Re:Banned C standard library functions in Git source code
by The_rationalist on Sunday August 25, 2019 @10:29AM
(#20793161)
Responsible? 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.
Re:Banned C standard library functions in Git source code
by zsrxx on Sunday August 25, 2019 @10:33AM
(#20793192)
I 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