autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 10-forbidden-tokens-in-comments.patch


From: Akim Demaille
Subject: Re: 10-forbidden-tokens-in-comments.patch
Date: 18 Jan 2001 10:10:22 +0100
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.1 (Crater Lake)

| Index: ChangeLog
| from  Akim Demaille  <address@hidden>
|         
|         * autoconf.sh (finalize.awk): Don't discard comments when looking
|         for unexpanded tokens.
|         Adjust Autoconf and its test suite.

I think there should be at least a small debate about this one.  What
do people think?  The problem is that when Autoconf was broken, it
*could* have found out something was fishy if it did check for
forbidden tokens in comments.  But it didn't, and the problem,
although huge, went unnoticed.

But this means that many people will see new pseudo-failures.

So...

1. do it just like for forbidden tokens in the text body: i.e., an
   error but output an hopefully valid configure (this is the patch
   below).

2. distinguish tokens in comments from tokens in the body, and output
   a different message.  Say a warning for comments.

3. same as above, but introduce a different warning which is not set
   by default.

4. don't do it at all.


Proposals classified with my decreasing preference.

        Akim

Index: autoconf.sh
--- autoconf.sh Sat, 13 Jan 2001 11:47:33 +0100 akim (ace/17_autoconf.s 1.31.8.4
0 666)
+++ autoconf.sh Wed, 17 Jan 2001 23:38:31 +0100 akim (ace/17_autoconf.s 1.31.8.4
0 666)
@@ -381,9 +381,6 @@
 
       print
 
-      # Dubious feature: we tolerate macro names when commented.
-      sub (/#.*/, "")
-
       # Get the tokens.
       split (\$0, tokens, /[^$WORDCHAR]*/)
 
@@ -401,6 +398,11 @@
     END {
       if (some_macros_were_not_expanded)
         {
+         errprint("$me: some forbidden tokens, most probably unexpanded macros,
")
+         errprint("$me: were found in the output and are listed below.")
+         errprint("$me: they might just appear in comments, they should not.")
+         errprint("$me: we suggest that you fix these issues, but the output")
+         errprint("$me: *has* been produced: use at your own risks.")
           line = 0
           while (getline < "$infile")
             {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]