The LLVM libc++ headers have a macro, used in function declarations, named _LIBCPP_INLINE_VISIBILITY
.
I don't understand what it means; I looked at its definition, and it says:
// Just so we can migrate to the new macros gradually.
#define _LIBCPP_INLINE_VISIBILITY _LIBCPP_HIDE_FROM_ABI
... and this second macro has no definition I can find. So, what does _LIBCPP_INLINE_VISIBILITY
mean and what is it typically expanded into?
(Thanks, @Ruslan)
The intent is to hide functions marked with it from appearing in dynamic libraries ("hide from the ABI"). This used to be done by making such functions inline
only, but now, the clang attribute attribute((internal_linkage))
is used; that's the definition of _LIBCPP_HIDE_FROM_ABI
.
As for the inline-for-invisibility macro _LIBCPP_INLINE_VISIBILITY
- what you're seeing is it being redefined to what its name should have been to being with.