Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
08d57b0da4 | ||
|
|
cbfda2da47 |
No files matched your search
@@ -0,0 +1,13 @@
|
|||||||
|
import java.lang.Integer;
|
||||||
|
import java.lang.Object;
|
||||||
|
import java.lang.System;
|
||||||
|
import java.io.PrintStream;
|
||||||
|
|
||||||
|
public class Bug466 {
|
||||||
|
public void p(Object o) { System.out.println(o.toString()); }
|
||||||
|
public run() {
|
||||||
|
var a = 3;
|
||||||
|
p(-(a + 10)); // Java: -13
|
||||||
|
}
|
||||||
|
public static main(args) { new Bug466().run(); }
|
||||||
|
}
|
||||||
@@ -1806,4 +1806,11 @@ public class TestComplete {
|
|||||||
var bnot = clazz.getDeclaredMethod("not", Integer.class);
|
var bnot = clazz.getDeclaredMethod("not", Integer.class);
|
||||||
assertEquals(-11, bnot.invoke(instance, 10));
|
assertEquals(-11, bnot.invoke(instance, 10));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testBug466() throws Exception {
|
||||||
|
var classFiles = generateClassFiles(createClassLoader(), "Bug466.jav");
|
||||||
|
var clazz = classFiles.get("Bug466");
|
||||||
|
clazz.getDeclaredMethod("main", List.class).invoke(null, List.of());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user