X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=opcode.pl;h=43d98ae8af50b88832c18866e5c54e4a7515ec32;hb=c5b802edbc2f0c65267eeef77229d452ab090751;hp=1c1d9bf8d6ee99c4389e43e37afc41174aaf12c0;hpb=297b36dcf845fc5195afb0a1d7e83d539bb1d4ed;p=p5sagit%2Fp5-mst-13.2.git diff --git a/opcode.pl b/opcode.pl index 1c1d9bf..43d98ae 100755 --- a/opcode.pl +++ b/opcode.pl @@ -193,6 +193,9 @@ END '}', 13, # loopexop ); +my %OP_IS_SOCKET; +my %OP_IS_FILETEST; + for (@ops) { $argsum = 0; $flags = $flags{$_}; @@ -210,7 +213,12 @@ for (@ops) { $argsum |= $opclass{$1} << 9; $mul = 0x2000; # 2 ^ OASHIFT for $arg (split(' ',$args{$_})) { + if ($arg =~ /^F/) { + $OP_IS_SOCKET{$_} = 1 if $arg =~ s/s//; + $OP_IS_FILETEST{$_} = 1 if $arg =~ s/-//; + } $argnum = ($arg =~ s/\?//) ? 8 : 0; + die "op = $_, arg = $arg\n" unless length($arg) == 1; $argnum += $argnum{$arg}; warn "# Conflicting bit 32 for '$_'.\n" if $argnum & 8 and $mul == 0x10000000; @@ -228,6 +236,20 @@ print <