http://llvm.org/bugs/show_bug.cgi?id=15305
Bug ID: 15305
Summary: clang accepts __attribute__ in more places than gcc
Product: clang
Version: unspecified
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: Frontend
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Classification: Unclassified
Gcc accepts __attribute__((visibility("hidden"))) anywhere it accepts 'static.
So it accepts
int __attribute__((visibility("hidden"))) foo() {
}
but rejects
int* __attribute__((visibility("hidden"))) bar() {
}
clang accepts both (but agrees with gcc as to where 'static' can be).
Not sure if this is an intended extension or not, but it can cause problems in
codebases where clang is the main compiler but gcc is still supported (as with
clang itself).
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs