mirror of
git://git.sv.gnu.org/autoconf
synced 2024-12-03 02:00:36 +08:00
* bin/autom4te.in (handle_output): Handle @__@.
This commit is contained in:
parent
ad80ccfe86
commit
22d6c214ea
@ -1,3 +1,7 @@
|
||||
2001-08-20 Akim Demaille <akim@epita.fr>
|
||||
|
||||
* bin/autom4te.in (handle_output): Handle @__@.
|
||||
|
||||
2001-08-20 Akim Demaille <akim@epita.fr>
|
||||
|
||||
* lib/autoconf/autoconf.m4, lib/autoconf/oldnames.m4,
|
||||
|
@ -581,6 +581,7 @@ sub handle_output ($$)
|
||||
my $separate = 0;
|
||||
my $oline = 0;
|
||||
my %prohibited;
|
||||
my $res;
|
||||
while ($_ = $in->getline)
|
||||
{
|
||||
s/\s+$//;
|
||||
@ -599,12 +600,13 @@ sub handle_output ($$)
|
||||
|
||||
$oline++;
|
||||
s/__oline__/$oline/g;
|
||||
|
||||
s/\@<:\@/[/g;
|
||||
s/\@:>\@/]/g;
|
||||
s/\@S\|\@/\$/g;
|
||||
s/\@%:\@/#/g;
|
||||
|
||||
print $out "$_\n";
|
||||
$res = $_;
|
||||
|
||||
# Don't complain in comments. Well, until we have something
|
||||
# better, don't consider `#include' etc. are comments.
|
||||
@ -615,6 +617,14 @@ sub handle_output ($$)
|
||||
$prohibited{$_} = $oline
|
||||
if /$forbidden/o && !/$allowed/o && ! exists $prohibited{$_};
|
||||
}
|
||||
|
||||
# Performed *last*: the empty quadrigraph. Handling it last
|
||||
# makes it possible to generate quadrigraphs, e.g. `@<@__@:@'
|
||||
# produces `@<:@'. In addition, it provides a means to
|
||||
# explicitly allow some *occurrences* of forbidden patterns.
|
||||
$res =~ s/\@__\@//g;
|
||||
|
||||
print $out "$res\n";
|
||||
}
|
||||
|
||||
# If no forbidden words, we're done.
|
||||
|
Loading…
Reference in New Issue
Block a user