Hi hackers,

While poking at the build system I stumbled upon some trivial trailer
comment inconsistencies in config/c-compiler.m4. They can be fixed
either way: either changing the macro names or changing the comment. PFA
a patch that keeps the macro names.

In hindsight though, it seems that PGAC_PRINTF_ARCHETYPE was meant to be
PGAC_C_PRINTF_ARCHETYPE, judging by a half-second squint of surrounding,
similar macros. Thoughts?

Also in hindsight: it seems that, as suggested in the trailer typo,
PGAC_PROG_CXX_VAR_OPT (a la the C version PGAC_PROG_CC_VAR_OPT) would be
a good addition if we ever want to add the negative warning flags (for
starter, Wno-unused-command-line-argument for clang++) to CXXFLAGS, but
I assume it wasn't there in the final patch because we didn't use it
(presumably because the patch was minimized?). Thoughts?

Cheers,
Jesse
From 73c15bfdea388347455810c3eb98dbff235d3d08 Mon Sep 17 00:00:00 2001
From: Jesse Zhang <sbjesse@gmail.com>
Date: Wed, 22 Apr 2020 06:51:05 -0700
Subject: [PATCH] Fix header / trailer typos for m4 macros

These seem like legit names in earlier iterations of respective patches
(commit b779168ffe33 "Detect PG_PRINTF_ATTRIBUTE automatically." and
commit 6869b4f25847 "Add C++ support to configure.") but the macro had
been renamed out of sync with the header / trailer comment in the final
committed patch.
---
 config/c-compiler.m4 | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/config/c-compiler.m4 b/config/c-compiler.m4
index 501b74b3a19..c48cba9cf9a 100644
--- a/config/c-compiler.m4
+++ b/config/c-compiler.m4
@@ -2,7 +2,7 @@
 # config/c-compiler.m4
 
 
-# PGAC_C_PRINTF_ARCHETYPE
+# PGAC_PRINTF_ARCHETYPE
 # -----------------------
 # Select the format archetype to be used by gcc to check printf-type functions.
 # We prefer "gnu_printf", as that most closely matches the features supported
@@ -466,7 +466,7 @@ undefine([Ac_cachevar])dnl
 # command-line option. If it does, add the string to CXXFLAGS.
 AC_DEFUN([PGAC_PROG_CXX_CFLAGS_OPT],
 [PGAC_PROG_VARCXX_VARFLAGS_OPT(CXX, CXXFLAGS, $1)
-])# PGAC_PROG_CXX_VAR_OPT
+])# PGAC_PROG_CXX_CFLAGS_OPT
 
 
 
-- 
2.26.2

Reply via email to