Skip to content
Permalink
Browse files
Minimal fixes to IR to get JRuby compiling again.
  • Loading branch information
chrisseaton committed Oct 12, 2014
1 parent c02df12 commit 440ee5394ad0d63d725fcd78ccc5128f4c596b2b
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 2 deletions.
@@ -94,7 +94,8 @@ public Instr clone(CloneInfo info) {
return new BreakInstr(returnValue.cloneForInlining(ii), scopeName);
}

return super.clone(ii);
throw new UnsupportedOperationException();
//return super.clone(ii);
}

@Override
@@ -49,7 +49,8 @@ public Instr clone(CloneInfo info) {
return new NonlocalReturnInstr(returnValue.cloneForInlining(ii), methodName, maybeLambda);
}

return super.clone(ii);
throw new UnsupportedOperationException();
//return super.clone(ii);
}

@Override
@@ -3,6 +3,7 @@
import org.jruby.ir.Operation;
import org.jruby.ir.operands.Operand;
import org.jruby.ir.operands.Variable;
import org.jruby.ir.transformations.inlining.CloneInfo;

public class ReceiveExceptionBase extends Instr implements ResultInstr, FixedArityInstr {
protected Variable result;
@@ -33,4 +34,10 @@ public String toString() {
public void updateResult(Variable v) {
this.result = v;
}

@Override
public Instr clone(CloneInfo info) {
throw new UnsupportedOperationException();
}

}
@@ -5,6 +5,7 @@
import org.jruby.ir.instructions.ResultInstr;
import org.jruby.ir.operands.Operand;
import org.jruby.ir.operands.Variable;
import org.jruby.ir.transformations.inlining.CloneInfo;

import java.util.Map;

@@ -44,4 +45,10 @@ public void simplifyOperands(Map<Operand, Operand> valueMap, boolean force) {
public String toString() {
return getResult() + " = " + getOperation() + "(" + val + ")";
}

@Override
public Instr clone(CloneInfo info) {
throw new UnsupportedOperationException();
}

}

2 comments on commit 440ee53

@chrisseaton
Copy link
Contributor Author

@chrisseaton chrisseaton commented on 440ee53 Oct 12, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@subbuss I think your previous commit didn't compile https://travis-ci.org/jruby/jruby/builds/37691500. I've done these minimal changes that at least get JRuby compiling again - but they're probably non-sensical for what you actually want to do in the IR.

@subbuss
Copy link
Contributor

@subbuss subbuss commented on 440ee53 Oct 12, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Chris. Will take a look and fix up later today.

Please sign in to comment.