]> granicus.if.org Git - postgresql/commitdiff
Dept of second thoughts: rename new perl script.
authorTom Lane <tgl@sss.pgh.pa.us>
Sun, 19 Feb 2017 21:41:51 +0000 (16:41 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Sun, 19 Feb 2017 21:41:51 +0000 (16:41 -0500)
It didn't take long at all for me to become irritated that the original
choice of name for this script resulted in "warning" showing up in several
places in build logs, because I tend to grep for that.  Change the script
name to avoid that.

src/Makefile.global.in
src/tools/fix-old-flex-code.pl [moved from src/tools/fix-flex-warning.pl with 91% similarity]
src/tools/msvc/pgflex.pl

index 35c8cb826ecc3d1507c4f4f911f73263bfa064f8..831d39a9d13aee8047ee3c8f33b66dddccba06dc 100644 (file)
@@ -627,7 +627,7 @@ TAS         = @TAS@
 ifdef FLEX
        $(FLEX) $(if $(FLEX_NO_BACKUP),-b) $(FLEXFLAGS) -o'$@' $<
        @$(if $(FLEX_NO_BACKUP),if [ `wc -l <lex.backup` -eq 1 ]; then rm lex.backup; else echo "Scanner requires backup; see lex.backup." 1>&2; exit 1; fi)
-       $(if $(FLEX_FIX_WARNING),$(PERL) $(top_srcdir)/src/tools/fix-flex-warning.pl '$@')
+       $(if $(FLEX_FIX_WARNING),$(PERL) $(top_srcdir)/src/tools/fix-old-flex-code.pl '$@')
 else
        @$(missing) flex $< '$@'
 endif
similarity index 91%
rename from src/tools/fix-flex-warning.pl
rename to src/tools/fix-old-flex-code.pl
index 14df02198fb5f11777e891e8299b15324342f395..8dafcae15e27c3073a4cbcb515ef0f3b822e5983 100644 (file)
@@ -1,7 +1,7 @@
 #!/usr/bin/perl -w
 #----------------------------------------------------------------------
 #
-# fix-flex-warning.pl
+# fix-old-flex-code.pl
 #
 # flex versions before 2.5.36, with certain option combinations, produce
 # code that causes an "unused variable" warning.  That's annoying, so
@@ -11,7 +11,7 @@
 # Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group
 # Portions Copyright (c) 1994, Regents of the University of California
 #
-# src/tools/fix-flex-warning.pl
+# src/tools/fix-old-flex-code.pl
 #
 #----------------------------------------------------------------------
 
@@ -55,9 +55,9 @@ exit 0;
 sub usage
 {
        die <<EOM;
-Usage: fix-flex-warning.pl c-file-name
+Usage: fix-old-flex-code.pl c-file-name
 
-fix-flex-warning.pl modifies a flex output file to suppress
+fix-old-flex-code.pl modifies a flex output file to suppress
 an unused-variable warning that occurs with older flex versions.
 
 Report bugs to <pgsql-bugs\@postgresql.org>.
index d590155f106cd544d3f80d39bcaba924c6d52ac2..fab0efa79fb2c663b5081a00b6c59fbb7b45a4c5 100644 (file)
@@ -60,7 +60,7 @@ if ($? == 0)
        {
                # Reentrant scanners usually need a fix to prevent
                # "unused variable" warnings with older flex versions.
-               system("perl src\\tools\\fix-flex-warning.pl $output");
+               system("perl src\\tools\\fix-old-flex-code.pl $output");
        }
        else
        {