diff options
author | Stephen McCamant <smcc@mit.edu> | 2002-01-10 10:21:34 -0800 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2002-01-11 14:52:51 +0000 |
commit | c517cc4736790bd45b954954a7697e5f9867154c (patch) | |
tree | 2e05a5823d68f96be978c65fe67a0c0f0c67ac32 | |
parent | 3acbd4f53b544ab36759ef8cf0a6fcc4f696a8d0 (diff) | |
download | perl-c517cc4736790bd45b954954a7697e5f9867154c.tar.gz |
Re: Magic numbers in B::Concise
Message-ID: <15422.19502.380275.403187@soda.csua.berkeley.edu>
p4raw-id: //depot/perl@14190
-rw-r--r-- | MANIFEST | 1 | ||||
-rw-r--r-- | ext/B/t/concise.t | 24 |
2 files changed, 25 insertions, 0 deletions
@@ -97,6 +97,7 @@ ext/B/t/asmdata.t See if B::Asmdata works ext/B/t/assembler.t See if B::Assembler, B::Disassembler comply ext/B/t/b.t See if B works ext/B/t/bblock.t See if B::Bblock works +ext/B/t/concise.t See whether B::Concise works ext/B/t/debug.t See if B::Debug works ext/B/t/deparse.t See if B::Deparse works ext/B/t/showlex.t See if B::ShowLex works diff --git a/ext/B/t/concise.t b/ext/B/t/concise.t new file mode 100644 index 0000000000..ad29c20329 --- /dev/null +++ b/ext/B/t/concise.t @@ -0,0 +1,24 @@ +#!./perl + +BEGIN { + chdir 't'; + @INC = '../lib'; + require './test.pl'; +} + +plan tests => 3; + +require_ok("B::Concise"); + +$out = runperl(switches => ["-MO=Concise"], prog => '$a', stderr => 1); + +# If either of the next two tests fail, it probably means you need to +# fix the section labeled 'fragile kludge' in Concise.pm + +$op_base = ($out =~ /^(\d+)\s*<0>\s*enter/m); + +is($op_base, 1, "Smallest OP sequence number", $help); + +$cop_base = ($out =~ /nextstate\(main (\d+) /); + +is($cop_base, 1, "Smallest COP sequence number", $help); |