[svn:parrot] r44750 - in branches/ops_pct/compilers/opsc: src/Ops/Compiler t
bacek at svn.parrot.org
bacek at svn.parrot.org
Sun Mar 7 21:25:12 UTC 2010
Author: bacek
Date: Sun Mar 7 21:25:11 2010
New Revision: 44750
URL: https://trac.parrot.org/parrot/changeset/44750
Log:
Other way around - add goto NEXT for non :flow ops...
Modified:
branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm
branches/ops_pct/compilers/opsc/t/03-past.t
Modified: branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm
==============================================================================
--- branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm Sun Mar 7 21:24:47 2010 (r44749)
+++ branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm Sun Mar 7 21:25:11 2010 (r44750)
@@ -78,7 +78,7 @@
$op<type> := ~$<op_type>;
$op<normalized_args> := @norm_args;
- if %flags<flow> {
+ if !%flags<flow> {
$op.push(PAST::Op.new(
:pasttype('inline'),
:inline("\n" ~ '{{+=OP_SIZE}};' ~ "\n")
Modified: branches/ops_pct/compilers/opsc/t/03-past.t
==============================================================================
--- branches/ops_pct/compilers/opsc/t/03-past.t Sun Mar 7 21:24:47 2010 (r44749)
+++ branches/ops_pct/compilers/opsc/t/03-past.t Sun Mar 7 21:25:11 2010 (r44750)
@@ -85,13 +85,15 @@
ok( ($op.arg_types).join('_') eq 'i_p_nc', "First variant correct");
-# Check body munching.
-ok( $op.body ~~ /OP_SIZE/, "goto NEXT appended for :flow ops");
# Second created op should have _pc_
$op := @ops[2];
ok( $op.arg_types.join('_') eq 'i_pc_nc', "Second variant correct");
+# Check body munching.
+$op := @ops[0];
+ok( $op.body ~~ /OP_SIZE/, "goto NEXT appended for non :flow ops");
+
# Don't forget to update plan!
More information about the parrot-commits
mailing list