https://bugs.llvm.org/show_bug.cgi?id=33796
Bug ID: 33796
Summary: availability attributes override visibility
Product: clang
Version: unspecified
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: C++
Assignee: unassignedclangb...@nondot.org
Reporter: nicolaswe...@gmx.de
CC: dgre...@apple.com, llvm-bugs@lists.llvm.org
We're moving Chrome to @available, which requires tagging some of our code with
API_AVAILABLE(10.10). However, that seems to also make classes visible, which
we don't want:
$ cat test.cc
#define F
class F Foo {
void f();
};
void Foo::f() {}
$ bin/clang -c test.cc -mmacosx-version-min=10.10 -fvisibility=hidden
-fvisibility-inlines-hidden && ld -dylib -o libtest.dylib test.o && nm
libtest.dylib
ld: warning: -macosx_version_min not specified, assuming 10.10
0000000000000fb0 t __ZN3Foo1fEv
$ cat test.cc
#define F __attribute__((availability(macos, introduced=10.11)))
class F Foo {
void f();
};
void Foo::f() {}
$ bin/clang -c test.cc -mmacosx-version-min=10.10 -fvisibility=hidden
-fvisibility-inlines-hidden && ld -dylib -o libtest.dylib test.o && nm
libtest.dylib
ld: warning: -macosx_version_min not specified, assuming 10.10
0000000000000fb0 T __ZN3Foo1fEv
That's hopefully just a bug, and not by design?
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs