Cleanup handling of visibility
This commit is contained in:
+5
-11
@@ -93,17 +93,11 @@
|
||||
# define FMT_NO_UNIQUE_ADDRESS
|
||||
#endif
|
||||
|
||||
#if FMT_GCC_VERSION || defined(__clang__)
|
||||
# define FMT_VISIBILITY(value) __attribute__((visibility(value)))
|
||||
// Visibility when compiled as a shared library/object.
|
||||
#if defined(FMT_LIB_EXPORT) || defined(FMT_SHARED)
|
||||
# define FMT_SO_VISIBILITY(value) FMT_VISIBILITY(value)
|
||||
#else
|
||||
# define FMT_VISIBILITY(value)
|
||||
#endif
|
||||
|
||||
#if !defined(FMT_HEADER_ONLY) && !defined(_WIN32) && \
|
||||
(defined(FMT_LIB_EXPORT) || defined(FMT_SHARED))
|
||||
# define FMT_INLINE_API FMT_VISIBILITY("default")
|
||||
#else
|
||||
# define FMT_INLINE_API
|
||||
# define FMT_SO_VISIBILITY(value)
|
||||
#endif
|
||||
|
||||
#ifdef __has_builtin
|
||||
@@ -1053,7 +1047,7 @@ FMT_BEGIN_EXPORT
|
||||
#endif
|
||||
|
||||
/** An error reported from a formatting function. */
|
||||
class FMT_INLINE_API format_error : public std::runtime_error {
|
||||
class FMT_SO_VISIBILITY("default") format_error : public std::runtime_error {
|
||||
public:
|
||||
using std::runtime_error::runtime_error;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user