Fix PIC_SYM() macro: it never needs to token paste, so it's not
authorguenther <guenther@openbsd.org>
Thu, 24 Feb 2022 07:08:21 +0000 (07:08 +0000)
committerguenther <guenther@openbsd.org>
Thu, 24 Feb 2022 07:08:21 +0000 (07:08 +0000)
dependent on __STDC__ and doesn't need the ## operator.

ok jsg@

sys/arch/arm/include/asm.h
sys/arch/arm64/include/asm.h
sys/arch/riscv64/include/asm.h

index e1e5bbc..1fc98c1 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: asm.h,v 1.9 2017/06/29 17:36:16 deraadt Exp $ */
+/*     $OpenBSD: asm.h,v 1.10 2022/02/24 07:08:21 guenther Exp $       */
 /*     $NetBSD: asm.h,v 1.4 2001/07/16 05:43:32 matt Exp $     */
 
 /*
 #define        END(y)          .size y, . - y
 
 #if defined(__PIC__)
-#ifdef __STDC__
-#define        PIC_SYM(x,y)    x ## ( ## y ## )
-#else
-#define        PIC_SYM(x,y)    x/**/(/**/y/**/)
-#endif
+#define        PIC_SYM(x,y)    x(y)
 #else
 #define        PIC_SYM(x,y)    x
 #endif
index 643a19c..396940e 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: asm.h,v 1.7 2022/02/23 07:16:26 jsg Exp $     */
+/*     $OpenBSD: asm.h,v 1.8 2022/02/24 07:08:21 guenther Exp $        */
 /*     $NetBSD: asm.h,v 1.4 2001/07/16 05:43:32 matt Exp $     */
 
 /*
 #define EEND(sym)
 
 #ifdef __PIC__
-#ifdef __STDC__
-#define        PIC_SYM(x,y)    x ## ( ## y ## )
-#else
-#define        PIC_SYM(x,y)    x/**/(/**/y/**/)
-#endif
+#define        PIC_SYM(x,y)    x(y)
 #else
 #define        PIC_SYM(x,y)    x
 #endif
index 746c355..44ecf69 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: asm.h,v 1.3 2022/02/23 07:16:26 jsg Exp $     */
+/*     $OpenBSD: asm.h,v 1.4 2022/02/24 07:08:21 guenther Exp $        */
 
 /*
  * Copyright (c) 2020 Brian Bamsch <bbamsch@google.com>
 #define EEND(sym)
 
 #ifdef __PIC__
-#ifdef __STDC__
-#define        PIC_SYM(x,y)    x ## ( ## y ## )
-#else
-#define        PIC_SYM(x,y)    x/**/(/**/y/**/)
-#endif
+#define        PIC_SYM(x,y)    x(y)
 #else
 #define        PIC_SYM(x,y)    x
 #endif