mirror of
https://github.com/postgres/postgres.git
synced 2025-09-02 04:21:28 +03:00
Rely on __func__ being supported
Previously we fell back to __FUNCTION__ and then NULL. As __func__ is in C99
that shouldn't be necessary anymore.
Solution.pm defined HAVE_FUNCNAME__FUNCTION instead of
HAVE_FUNCNAME__FUNC (originating in 4164e6636e
), as at some point in the past
MSVC only supported __FUNCTION__. Our minimum version supports __func__.
Reviewed-By: Thomas Munro <thomas.munro@gmail.com>
Discussion: https://postgr.es/m/20220807012914.ydz73yte6j3coulo@awork3.anarazel.de
This commit is contained in:
@@ -304,7 +304,7 @@ main()
|
||||
printf(" if S_LOCK() and TAS() are working.\n");
|
||||
fflush(stdout);
|
||||
|
||||
s_lock(&test_lock.lock, __FILE__, __LINE__, PG_FUNCNAME_MACRO);
|
||||
s_lock(&test_lock.lock, __FILE__, __LINE__, __func__);
|
||||
|
||||
printf("S_LOCK_TEST: failed, lock not locked\n");
|
||||
return 1;
|
||||
|
Reference in New Issue
Block a user