Re: remove some STATUS_* symbols
Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Michael Paquier <michael@paquier.xyz>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2020-01-09T10:15:08Z
Lists: pgsql-hackers
On 2020-01-06 07:31, Michael Paquier wrote: > On Sun, Dec 29, 2019 at 11:33:34AM +0100, Peter Eisentraut wrote: >> Attached are two patches to remove these two symbols. STATUS_FOUND can be >> replaced by a simple bool. STATUS_WAITING is replaced by a separate enum. > > Patch 0001 looks good to me, but I got to wonder why the check after > waitMask in LockAcquireExtended() is not done directly in > LockCheckConflicts(). You mean put he subsequent GrantLock() calls into LockCheckConflicts()? That would technically save some duplicate code, but it seems weird, because LockCheckConflicts() is notionally a read-only function that shouldn't change state. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Commits
-
Remove STATUS_WAITING
- a513f1dfbf2c 14.0 landed
-
Remove STATUS_FOUND
- c096a804d9dc 13.0 landed