diff options
| author | fukachan <fukachan> | 2003-01-11 16:08:44 +0000 |
|---|---|---|
| committer | fukachan <fukachan> | 2003-01-11 16:08:44 +0000 |
| commit | 40259248fbc26916031af1f071896a0211df2566 (patch) | |
| tree | 8c21e84c2e41144ef98c022f6700c07ba4c4c48e | |
| parent | bd8cf6b67f3ebacfc1bf374bf507be9d49ffe85b (diff) | |
| download | fml8-40259248fbc26916031af1f071896a0211df2566.tar.gz fml8-40259248fbc26916031af1f071896a0211df2566.tar.bz2 fml8-40259248fbc26916031af1f071896a0211df2566.zip | |
reset if encounted with "sub ... {}" line.
handle [XXX($var)] style.
| -rwxr-xr-x | regress/simulation/find_bad_style.pl | 5 | ||||
| -rwxr-xr-x | regress/style/find_bad_style.pl | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/regress/simulation/find_bad_style.pl b/regress/simulation/find_bad_style.pl index e6a6e639..8b0e3388 100755 --- a/regress/simulation/find_bad_style.pl +++ b/regress/simulation/find_bad_style.pl @@ -5,7 +5,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: find_bad_style.pl,v 1.2 2003/01/03 10:16:33 fukachan Exp $ +# $FML: find_bad_style.pl,v 1.3 2003/01/03 11:49:58 fukachan Exp $ # use strict; @@ -90,6 +90,7 @@ while (<>) { _check_args( $ARGV, $_ ); } $fnf_args = '' if /^\}/; + $fnf_args = '' if /^sub .*\}/; # # last resort: logging buffer @@ -208,6 +209,8 @@ sub _check_args $fnf =~ s/\n/ /g; for (split(/\s+/, $fnf)) { + s/\[//g; + s/\]//g; if (/^\w+\((\S+)\)/) { push(@fnf, $1); } diff --git a/regress/style/find_bad_style.pl b/regress/style/find_bad_style.pl index e6a6e639..8b0e3388 100755 --- a/regress/style/find_bad_style.pl +++ b/regress/style/find_bad_style.pl @@ -5,7 +5,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: find_bad_style.pl,v 1.2 2003/01/03 10:16:33 fukachan Exp $ +# $FML: find_bad_style.pl,v 1.3 2003/01/03 11:49:58 fukachan Exp $ # use strict; @@ -90,6 +90,7 @@ while (<>) { _check_args( $ARGV, $_ ); } $fnf_args = '' if /^\}/; + $fnf_args = '' if /^sub .*\}/; # # last resort: logging buffer @@ -208,6 +209,8 @@ sub _check_args $fnf =~ s/\n/ /g; for (split(/\s+/, $fnf)) { + s/\[//g; + s/\]//g; if (/^\w+\((\S+)\)/) { push(@fnf, $1); } |
