https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111708
--- Comment #5 from Kirill Frolov <k.frolov at samsung dot com> --- C standard states,that: 6.2.2 Linkages of identifiers 7) If, within a translation unit, the same identifier appears with both internal and external linkage, the behavior is undefined. So, I think only ICC has adequate behaviour. Other compilers miss at least warning message.