1 /* 2 * @test /nodynamiccopyright/ 3 * @bug 6911256 6964740 6965277 4 * @author Maurizio Cimadamore 5 * @summary Verify that method type-inference works as expected in ARM context 6 * @compile ArmInference.java 7 */ 8 9 class ArmInference { 10 11 public void test() { 12 try(getX()) { 13 //do something 14 } catch (Exception e) { // Not reachable 15 throw new AssertionError("Shouldn't reach here", e); 16 } 17 } 18 19 <X> X getX() { return null; } 20 }