diff options
author | Andres Freund <andres@anarazel.de> | 2018-08-24 10:41:45 -0700 |
---|---|---|
committer | Andres Freund <andres@anarazel.de> | 2018-08-24 10:41:45 -0700 |
commit | 8ecdefc261abbd35d6280cdd8fd749e83c3fd199 (patch) | |
tree | 3c10a717339808e8741c05dca6796d2a614dd1e1 /src/include/utils/elog.h | |
parent | cb92520563834577d3afbbedcc0df4ee0aac3445 (diff) | |
download | postgresql-8ecdefc261abbd35d6280cdd8fd749e83c3fd199.tar.gz postgresql-8ecdefc261abbd35d6280cdd8fd749e83c3fd199.zip |
Remove test for VA_ARGS, implied by C99.
This simplifies logic / reduces duplication in a few headers.
Author: Andres Freund
Discussion: https://postgr.es/m/97d4b165-192d-3605-749c-f614a0c4e783@2ndquadrant.com
Diffstat (limited to 'src/include/utils/elog.h')
-rw-r--r-- | src/include/utils/elog.h | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/include/utils/elog.h b/src/include/utils/elog.h index 4350b120aab..33c6b53e278 100644 --- a/src/include/utils/elog.h +++ b/src/include/utils/elog.h @@ -207,9 +207,8 @@ extern int getinternalerrposition(void); * elog(ERROR, "portal \"%s\" not found", stmt->portalname); *---------- */ -#ifdef HAVE__VA_ARGS /* - * If we have variadic macros, we can give the compiler a hint about the + * Using variadic macros, we can give the compiler a hint about the * call not returning when elevel >= ERROR. See comments for ereport(). * Note that historically elog() has called elog_start (which saves errno) * before evaluating "elevel", so we preserve that behavior here. @@ -236,11 +235,6 @@ extern int getinternalerrposition(void); } \ } while(0) #endif /* HAVE__BUILTIN_CONSTANT_P */ -#else /* !HAVE__VA_ARGS */ -#define elog \ - elog_start(__FILE__, __LINE__, PG_FUNCNAME_MACRO), \ - elog_finish -#endif /* HAVE__VA_ARGS */ extern void elog_start(const char *filename, int lineno, const char *funcname); extern void elog_finish(int elevel, const char *fmt,...) pg_attribute_printf(2, 3); |