Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Ensure CSD is updated.
Means that the multi-dispatcher sees the args it's meant to.
  • Loading branch information
jnthn committed May 10, 2013
1 parent 1a2fcbd commit 111de52
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/vm/jvm/Perl6/Ops.nqp
Expand Up @@ -40,7 +40,8 @@ $ops.add_hll_op('perl6', 'p6bindsig', -> $qastcomp, $op {
$il.append(JAST::Instruction.new( :op('aload'), 'csd' ));
$il.append(JAST::Instruction.new( :op('aload'), '__args' ));
$il.append(JAST::Instruction.new( :op('invokestatic'), $TYPE_P6OPS,
"p6bindsig", 'V', $TYPE_TC, $TYPE_CSD, "[$TYPE_OBJ" ));
"p6bindsig", $TYPE_CSD, $TYPE_TC, $TYPE_CSD, "[$TYPE_OBJ" ));
$il.append(JAST::Instruction.new( :op('astore'), 'csd' ));
$ops.result($il, $RT_VOID);
});
$ops.map_classlib_hll_op('perl6', 'p6isbindable', $TYPE_P6OPS, 'p6isbindable', [$RT_OBJ, $RT_OBJ], $RT_INT, :tc);
Expand Down
4 changes: 3 additions & 1 deletion src/vm/jvm/runtime/org/perl6/rakudo/Ops.java
Expand Up @@ -40,7 +40,7 @@ public static SixModelObject booleanize(int x) {
return x == 0 ? False : True;
}

public static void p6bindsig(ThreadContext tc, CallSiteDescriptor csd, Object[] args) {
public static CallSiteDescriptor p6bindsig(ThreadContext tc, CallSiteDescriptor csd, Object[] args) {
/* Do any flattening before processing begins. */
CallFrame cf = tc.curFrame;
if (csd.hasFlattening) {
Expand All @@ -64,5 +64,7 @@ public static void p6bindsig(ThreadContext tc, CallSiteDescriptor csd, Object[]
case Binder.BIND_RESULT_JUNCTION:
throw ExceptionHandling.dieInternal(tc, "Junction re-dispatch NYI");
}

return csd;
}
}

0 comments on commit 111de52

Please sign in to comment.