[PATCH] rename _LIBCPP_TYPE_VIS_ONLY to _LIBCPP_TEMPLATE_VIS
Reid Kleckner
rnk at google.com
Tue Jul 29 17:30:34 PDT 2014
I don't think we should be using this linkage on non-template types, even if Howard thought they were "header only". Even those tag types can be exported from libc++. If someone takes the address of a tag or once_flag assignment operator, libc++ should have a definition of it. Marking it as dllexport (aka _LIBCPP_TYPE_VISIBILITY) makes that work.
On the other hand, we have things like struct nullptr_t, which are never compiled while building libc++ itself. Saleem has moved to give them no decoration, which means each DSO would get its own set of member functions with distinct addresses.
The upshot is I think we should go forward with this change. This attribute really shouldn't be applied to non-template types, despite what Howard said in the past.
http://reviews.llvm.org/D4530
More information about the llvm-commits
mailing list