aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Support/Compiler.h
diff options
context:
space:
mode:
authorEdwin Török <edwintorok@gmail.com>2009-07-07 17:32:34 +0000
committerEdwin Török <edwintorok@gmail.com>2009-07-07 17:32:34 +0000
commitf7cbfea6ad05c37faa3449be206c7d60f8252f5d (patch)
tree038fcdc29c6f146048427213045ae05a3e4fe0b8 /include/llvm/Support/Compiler.h
parent6a3fb987360ceb2d861aab450f789729317a2e56 (diff)
downloadexternal_llvm-f7cbfea6ad05c37faa3449be206c7d60f8252f5d.zip
external_llvm-f7cbfea6ad05c37faa3449be206c7d60f8252f5d.tar.gz
external_llvm-f7cbfea6ad05c37faa3449be206c7d60f8252f5d.tar.bz2
Introduce new error handling API.
This will replace exit()/abort() style error handling with an API that allows clients to register custom error handling hooks. The default is to call exit(1) when no error handler is provided. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74922 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support/Compiler.h')
-rw-r--r--include/llvm/Support/Compiler.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/llvm/Support/Compiler.h b/include/llvm/Support/Compiler.h
index 90292df..8533246 100644
--- a/include/llvm/Support/Compiler.h
+++ b/include/llvm/Support/Compiler.h
@@ -56,4 +56,10 @@
#define DISABLE_INLINE
#endif
+#ifdef __GNUC__
+#define NORETURN __attribute__((noreturn))
+#else
+#define NORETURN
+#endif
+
#endif