What does the -fheinous-gnu-extensions option do?

When Homebrew compiles libgcrypt on OS X, it fixes its use of clang and adds -std=gnu89 and -fheinous-gnu-extensions to CFLAG Makefile var. What do the latter do?

+6
source share
1 answer

https://clang.llvm.org/doxygen/SemaStmtAsm_8cpp.html says:

GNU C has an extremely ugly extension, thanks to which they silently ignore "noop" in places where the lvalue is required by the built-in asm. We emulate this behavior when -fheinous-gnu-extensions is specified, but we give strong guidance not to use it.

No, I did not use it; I do not know why Homebrew needed this.

+8
source

Source: https://habr.com/ru/post/955930/


All Articles