logoalt Hacker News

uecker12/09/20241 replyview on HN

It is neither portable nor obviously correct.


Replies

quotemstr12/09/2024

Yes, it's both. It works fine in real world million line codebases. I have never, not once, seen a bug or portability issue caused by it. I have seen multiple header guard macro names collide.

Eschewing pragma once these days is pure ignorance and superstition --- then again, so is writing new code in C at all.

show 2 replies