https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104631

--- Comment #2 from Max S. <max.sagebaum at scicomp dot uni-kl.de> ---
Ok, thank you for the answer. In the example I can set this for the class but,
in the library it would be problematic. So here the best solution would be to
set the whole library to default.

Since the user should decide how the visibility of the library is, we do not
want to set it to default. Since after all, our library could only be used in a
library of the user and other programs never need to see it.

But we would like to warn the user if our library is included with visibility
hidden. 

Is there a preprocessor macro that can provide this information? 

Or is it possible to detect the visibility of a type during compile time in
order to trigger a static assert?

Thanks.

Reply via email to