diff options
author | Robert Haas | 2013-06-28 13:30:38 +0000 |
---|---|---|
committer | Robert Haas | 2013-06-28 13:33:34 +0000 |
commit | 5ee73525d57380a55b5c87f8df1c30bd32fb98b3 (patch) | |
tree | 94ed86e2f7b3c685165f032ad0f5d22db90e390f /src/include/c.h | |
parent | 9e0bc7c1e84d7fffb93130f2b7d079a0853329ed (diff) |
Define Trap and TrapMacro even in non-cassert builds.
In some cases, the use of these macros may be preferable to Assert()
or AssertMacro(), since this way the caller can set the trap message.
Andres Freund and Robert Haas
Diffstat (limited to 'src/include/c.h')
-rw-r--r-- | src/include/c.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/include/c.h b/src/include/c.h index f2c9e12fb3..596118342d 100644 --- a/src/include/c.h +++ b/src/include/c.h @@ -573,6 +573,9 @@ typedef NameData *Name; #define AssertMacro(condition) ((void)true) #define AssertArg(condition) #define AssertState(condition) +#define Trap(condition, errorType) +#define TrapMacro(condition, errorType) (true) + #elif defined(FRONTEND) #include <assert.h> |