]> granicus.if.org Git - postgresql/commitdiff
Remove unused, and dangerous, TestLatch() macro.
authorAndres Freund <andres@anarazel.de>
Fri, 18 Mar 2016 18:43:59 +0000 (11:43 -0700)
committerAndres Freund <andres@anarazel.de>
Fri, 18 Mar 2016 18:46:42 +0000 (11:46 -0700)
The macro has not seen any in-tree use since latches had been introduced
in 2746e5f, in 2010.

src/include/storage/latch.h

index e77491e71f38e14500a859b2e9042da1f3d7660c..737e11d016833ba5a15733d3517b9bf7438827f1 100644 (file)
@@ -116,8 +116,6 @@ extern int WaitLatchOrSocket(volatile Latch *latch, int wakeEvents,
 extern void SetLatch(volatile Latch *latch);
 extern void ResetLatch(volatile Latch *latch);
 
-/* beware of memory ordering issues if you use this macro! */
-#define TestLatch(latch) (((volatile Latch *) (latch))->is_set)
 
 /*
  * Unix implementation uses SIGUSR1 for inter-process signaling.