summaryrefslogtreecommitdiffstats
path: root/generic/tkInt.h
diff options
context:
space:
mode:
authordas <das>2009-08-24 03:18:23 (GMT)
committerdas <das>2009-08-24 03:18:23 (GMT)
commit976f8a2c8d9cd0b36533fc9d2d5a6341e5386570 (patch)
tree9d8b6543b65343871e4e186ec945d131cf795768 /generic/tkInt.h
parente3f160bf9b969a5130fd5f5b58c9fa44f6d7bbe4 (diff)
downloadtk-976f8a2c8d9cd0b36533fc9d2d5a6341e5386570.zip
tk-976f8a2c8d9cd0b36533fc9d2d5a6341e5386570.tar.gz
tk-976f8a2c8d9cd0b36533fc9d2d5a6341e5386570.tar.bz2
* generic/tkInt.h: Annotate Tcl_Panic as noreturn for clang static
analyzer in PURIFY builds, replacing preprocessor/assert technique.
Diffstat (limited to 'generic/tkInt.h')
-rw-r--r--generic/tkInt.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/generic/tkInt.h b/generic/tkInt.h
index 958695e..d43278a 100644
--- a/generic/tkInt.h
+++ b/generic/tkInt.h
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: $Id: tkInt.h,v 1.107 2009/08/19 23:02:00 pspjuth Exp $
+ * RCS: $Id: tkInt.h,v 1.108 2009/08/24 03:18:23 das Exp $
*/
#ifndef _TKINT
@@ -989,9 +989,7 @@ MODULE_SCOPE Tcl_HashTable tkPredefBitmapTable;
#if defined(PURIFY) && defined(__clang__) && !defined(CLANG_ASSERT)
#include <assert.h>
#define CLANG_ASSERT(x) assert(x)
-#define TclPanic Tcl_Panic
-#undef Tcl_Panic
-#define Tcl_Panic(f, ...) do { TclPanic(f,##__VA_ARGS__); CLANG_ASSERT(0); } while(0)
+EXTERN void Tcl_Panic(const char * format, ...) __attribute__((analyzer_noreturn));
#elif !defined(CLANG_ASSERT)
#define CLANG_ASSERT(x)
#endif