summaryrefslogtreecommitdiff
path: root/boost/config/suffix.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/config/suffix.hpp')
-rw-r--r--boost/config/suffix.hpp16
1 files changed, 13 insertions, 3 deletions
diff --git a/boost/config/suffix.hpp b/boost/config/suffix.hpp
index 17bf1020f5..eeaec2bf69 100644
--- a/boost/config/suffix.hpp
+++ b/boost/config/suffix.hpp
@@ -624,12 +624,22 @@ namespace std{ using ::type_info; }
# define BOOST_NORETURN __declspec(noreturn)
# elif defined(__GNUC__)
# define BOOST_NORETURN __attribute__ ((__noreturn__))
-# else
-# define BOOST_NO_NORETURN
-# define BOOST_NORETURN
+# elif defined(__has_attribute) && defined(__SUNPRO_CC)
+# if __has_attribute(noreturn)
+# define BOOST_NORETURN [[noreturn]]
+# endif
+# elif defined(__has_cpp_attribute)
+# if __has_cpp_attribute(noreturn)
+# define BOOST_NORETURN [[noreturn]]
+# endif
# endif
#endif
+#if !defined(BOOST_NORETURN)
+# define BOOST_NO_NORETURN
+# define BOOST_NORETURN
+#endif
+
// Branch prediction hints
// These macros are intended to wrap conditional expressions that yield true or false
//