diff options
author | 2008-09-29 17:17:50 +0000 | |
---|---|---|
committer | 2008-09-29 17:17:50 +0000 | |
commit | 850e275390052b330d93020bf619a739a3c277ac (patch) | |
tree | db372d287586cf504a5ead4801f6c6cf7eb31449 /gnu/usr.bin/perl/ext/re/t/lexical_debug.pl | |
parent | more updates on which args do and do not mix (doc only, this time): (diff) | |
download | wireguard-openbsd-850e275390052b330d93020bf619a739a3c277ac.tar.xz wireguard-openbsd-850e275390052b330d93020bf619a739a3c277ac.zip |
import perl 5.10.0 from CPAN
Diffstat (limited to 'gnu/usr.bin/perl/ext/re/t/lexical_debug.pl')
-rw-r--r-- | gnu/usr.bin/perl/ext/re/t/lexical_debug.pl | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/gnu/usr.bin/perl/ext/re/t/lexical_debug.pl b/gnu/usr.bin/perl/ext/re/t/lexical_debug.pl new file mode 100644 index 00000000000..3ec7455ba1a --- /dev/null +++ b/gnu/usr.bin/perl/ext/re/t/lexical_debug.pl @@ -0,0 +1,29 @@ +use re 'debug'; + +$_ = 'foo bar baz bop fip fop'; + +/foo/ and $count++; + +{ + no re 'debug'; + /bar/ and $count++; + { + use re 'debug'; + /baz/ and $count++; + } + /bop/ and $count++; +} + +/fip/ and $count++; + +no re 'debug'; + +/fop/ and $count++; + +use re 'debug'; +my $var='zoo|liz|zap'; +/($var)/ or $count++; + +print "Count=$count\n"; + + |