summaryrefslogtreecommitdiff
path: root/regen/opcode.pl
diff options
context:
space:
mode:
Diffstat (limited to 'regen/opcode.pl')
-rwxr-xr-xregen/opcode.pl33
1 files changed, 16 insertions, 17 deletions
diff --git a/regen/opcode.pl b/regen/opcode.pl
index a8f5e0b845..dd53aec81b 100755
--- a/regen/opcode.pl
+++ b/regen/opcode.pl
@@ -4,7 +4,7 @@
#
# opcode.h
# opnames.h
-# pp.sym
+# pp_proto.h
#
# from information stored in regen/opcodes, plus the
# values hardcoded into this script in @raw_alias.
@@ -468,33 +468,32 @@ safer_close($on);
rename_if_different $opcode_new, 'opcode.h';
rename_if_different $opname_new, 'opnames.h';
-my $pp_sym_new = 'pp.sym-new';
-my $ppsym = safer_open($pp_sym_new);
+my $pp_proto_new = 'pp_proto.h-new';
-print $ppsym <<"END";
-# -*- buffer-read-only: t -*-
-#
-# !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
-# This file is built by regen/opcode.pl from its data. Any changes made
-# here will be lost!
-#
+my $pp = safer_open($pp_proto_new);
-END
+print $pp <<"END";
+/* -*- buffer-read-only: t -*-
+ !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
+ This file is built by opcode.pl from its data. Any changes made here
+ will be lost!
+*/
+END
-for (@ops) {
+for (sort @ops) {
next if /^i_(pre|post)(inc|dec)$/;
next if /^custom$/;
- print $ppsym "Perl_pp_$_\n";
+ print $pp "PERL_CALLCONV OP *Perl_pp_$_(pTHX);\n";
}
-print $ppsym "\n# ex: set ro:\n";
+print $pp "\n/* ex: set ro: */\n";
-safer_close($ppsym);
+safer_close($pp);
-rename_if_different $pp_sym_new, 'pp.sym';
+rename_if_different $pp_proto_new, 'pp_proto.h';
END {
- foreach ('opcode.h', 'opnames.h', 'pp.sym') {
+ foreach ('opcode.h', 'opnames.h', 'pp_proto.h') {
1 while unlink "$_-old";
}
}