Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix yet more incorrect op signatures.
  • Loading branch information
jnthn committed Jul 21, 2012
1 parent 939c9ff commit 60afa48
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 7 deletions.
11 changes: 10 additions & 1 deletion src/QAST/Compiler.nqp
Expand Up @@ -529,8 +529,17 @@ class QAST::Compiler is HLL::Compiler {

multi method as_post(QAST::Op $node) {
my $hll := '';
my $result;
my $err;
try $hll := $*HLL;
QAST::Operations.compile_op(self, $hll, $node)
try {
$result := QAST::Operations.compile_op(self, $hll, $node);
CATCH { $err := $! }
}
if $err {
nqp::die("Error while compiling op " ~ $node.op ~ ": $err");
}
$result
}

multi method as_post(QAST::VM $node) {
Expand Down
12 changes: 6 additions & 6 deletions src/QAST/Operations.nqp
Expand Up @@ -1257,13 +1257,13 @@ QAST::Operations.add_core_pirop_mapping('push_s', 'push', '0Ps');
QAST::Operations.add_core_pirop_mapping('push_i', 'push', '0Pi');
QAST::Operations.add_core_pirop_mapping('push_n', 'push', '0Pn');
QAST::Operations.add_core_pirop_mapping('pop', 'pop', 'PP');
QAST::Operations.add_core_pirop_mapping('pop_s', 'pop', 'sP');
QAST::Operations.add_core_pirop_mapping('pop_i', 'pop', 'iP');
QAST::Operations.add_core_pirop_mapping('pop_n', 'pop', 'nP');
QAST::Operations.add_core_pirop_mapping('pop_s', 'pop', 'SP');
QAST::Operations.add_core_pirop_mapping('pop_i', 'pop', 'IP');
QAST::Operations.add_core_pirop_mapping('pop_n', 'pop', 'NP');
QAST::Operations.add_core_pirop_mapping('shift', 'shift', 'PP');
QAST::Operations.add_core_pirop_mapping('shift_s', 'shift', 'sP');
QAST::Operations.add_core_pirop_mapping('shift_i', 'shift', 'iP');
QAST::Operations.add_core_pirop_mapping('shift_n', 'shift', 'nP');
QAST::Operations.add_core_pirop_mapping('shift_s', 'shift', 'SP');
QAST::Operations.add_core_pirop_mapping('shift_i', 'shift', 'IP');
QAST::Operations.add_core_pirop_mapping('shift_n', 'shift', 'NP');
QAST::Operations.add_core_pirop_mapping('unshift', 'unshift', '0PP');
QAST::Operations.add_core_pirop_mapping('unshift_s', 'unshift', '0Ps');
QAST::Operations.add_core_pirop_mapping('unshift_i', 'unshift', '0Pi');
Expand Down

0 comments on commit 60afa48

Please sign in to comment.