X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=regcomp.pl;h=febd5505521923dbcfad170f815c2d429c936ebc;hb=b2a156bd8e464af88881c77344280160fd844dcf;hp=6ae847882d49aa0217a3c77f91acf6c5eab46f6b;hpb=22d4bb9ccb8701e68f9243547d7e3a3c55f70908;p=p5sagit%2Fp5-mst-13.2.git diff --git a/regcomp.pl b/regcomp.pl index 6ae8478..febd550 100644 --- a/regcomp.pl +++ b/regcomp.pl @@ -1,3 +1,7 @@ +BEGIN { + # Get function prototypes + require 'regen_lib.pl'; +} #use Fatal qw(open close rename chmod unlink); open DESC, 'regcomp.sym'; $ind = 0; @@ -12,15 +16,19 @@ while () { } close DESC; $tot = $ind; +die "Too many regexp opcodes! Maximum is 256, but there are $tot in file!" + if $tot>256; $tmp_h = 'tmp_reg.h'; unlink $tmp_h if -f $tmp_h; open OUT, ">$tmp_h"; +binmode OUT; print OUT <