Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 825e9a0760dc
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: c55574d00e0e
Choose a head ref
  • 3 commits
  • 3 files changed
  • 1 contributor

Commits on Sep 25, 2017

  1. Copy the full SHA
    7b650bd View commit details
  2. Copy the full SHA
    b4eb354 View commit details
  3. Copy the full SHA
    c55574d View commit details
Original file line number Diff line number Diff line change
@@ -213,8 +213,8 @@ public void invokeinterface(String arg1, String arg2, String arg3) {
getMethodVisitor().visitMethodInsn(INVOKEINTERFACE, arg1, arg2, arg3, true);
}

public void invokedynamic(String arg0, String arg1, Handle arg2, Object... arg3) {
getMethodVisitor().visitInvokeDynamicInsn(arg0, arg1, arg2, arg3);
public void invokedynamic(String name, String desc, Handle handle, Object... args) {
getMethodVisitor().visitInvokeDynamicInsn(name, desc, handle, args);
}

public void aprintln() {
4 changes: 2 additions & 2 deletions core/src/main/java/org/jruby/runtime/Helpers.java
Original file line number Diff line number Diff line change
@@ -2251,8 +2251,8 @@ static IRubyObject[] restructureBlockArgs(ThreadContext context,
if (value == null) return IRubyObject.NULL_ARRAY;

if (needsSplat) {
value = Helpers.aryToAry(context, value);
if (value instanceof RubyArray) return ((RubyArray) value).toJavaArrayMaybeUnsafe();
IRubyObject ary = Helpers.aryToAry(context, value);
if (ary instanceof RubyArray) return ((RubyArray) ary).toJavaArrayMaybeUnsafe();
}

return new IRubyObject[] { value };
Original file line number Diff line number Diff line change
@@ -86,10 +86,12 @@ public class MathLinker {
public static final MethodHandle FIXNUM_BOOLEAN = Binder.from(methodType(boolean.class, ThreadContext.class, IRubyObject.class, IRubyObject.class, JRubyCallSite.class, long.class)).invokeStaticQuiet(lookup(), MathLinker.class, "fixnumBoolean");
public static final MethodHandle FLOAT_OPERATOR = Binder.from(methodType(IRubyObject.class, ThreadContext.class, IRubyObject.class, IRubyObject.class, JRubyCallSite.class, double.class)).invokeStaticQuiet(lookup(), MathLinker.class, "floatOperator");

private static final CallType[] CALL_TYPES = CallType.values();

public static CallSite fixnumOperatorBootstrap(Lookup lookup, String name, MethodType type, long value, int callType, String file, int line) throws NoSuchMethodException, IllegalAccessException {
List<String> names = StringSupport.split(name, ':');
String operator = JavaNameMangler.demangleMethodName(names.get(1));
JRubyCallSite site = new JRubyCallSite(lookup, type, CallType.values()[callType], file, line, operator, true);
JRubyCallSite site = new JRubyCallSite(lookup, type, CALL_TYPES[callType], file, line, operator, true);

MethodHandle target = FIXNUM_OPERATOR;
target = insertArguments(target, 3, site, value);
@@ -101,7 +103,7 @@ public static CallSite fixnumOperatorBootstrap(Lookup lookup, String name, Metho
public static CallSite fixnumBooleanBootstrap(Lookup lookup, String name, MethodType type, long value, int callType, String file, int line) throws NoSuchMethodException, IllegalAccessException {
List<String> names = StringSupport.split(name, ':');
String operator = JavaNameMangler.demangleMethodName(names.get(1));
JRubyCallSite site = new JRubyCallSite(lookup, type, CallType.values()[callType], file, line, operator, true);
JRubyCallSite site = new JRubyCallSite(lookup, type, CALL_TYPES[callType], file, line, operator, true);

MethodHandle target = FIXNUM_BOOLEAN;
target = insertArguments(target, 3, site, value);
@@ -113,7 +115,7 @@ public static CallSite fixnumBooleanBootstrap(Lookup lookup, String name, Method
public static CallSite floatOperatorBootstrap(Lookup lookup, String name, MethodType type, double value, int callType, String file, int line) throws NoSuchMethodException, IllegalAccessException {
List<String> names = StringSupport.split(name, ':');
String operator = JavaNameMangler.demangleMethodName(names.get(1));
JRubyCallSite site = new JRubyCallSite(lookup, type, CallType.values()[callType], file, line, operator, true);
JRubyCallSite site = new JRubyCallSite(lookup, type, CALL_TYPES[callType], file, line, operator, true);

MethodHandle target = FLOAT_OPERATOR;