< prev index next >

src/java.base/share/classes/com/sun/java/util/jar/pack/Instruction.java

Print this page




 662             if (e != null) {
 663                 byte tag = i.getCPTag();
 664                 boolean match = e.tagMatches(tag);
 665                 if (!match &&
 666                         (i.bc == _invokespecial || i.bc == _invokestatic) &&
 667                         e.tagMatches(CONSTANT_InterfaceMethodref) &&
 668                         clsVersion.greaterThan(Constants.JAVA7_MAX_CLASS_VERSION)) {
 669                     match = true;
 670                 }
 671                 if (!match) {
 672                     String message = "illegal reference, expected type="
 673                             + ConstantPool.tagName(tag) + ": "
 674                             + i.toString(cpMap);
 675                     throw new FormatException(message);
 676                 }
 677             }
 678             i = i.next();
 679         }
 680     }
 681     static class FormatException extends IOException {

 682         private static final long serialVersionUID = 3175572275651367015L;
 683 
 684         FormatException(String message) {
 685             super(message);
 686         }
 687     }
 688 }


 662             if (e != null) {
 663                 byte tag = i.getCPTag();
 664                 boolean match = e.tagMatches(tag);
 665                 if (!match &&
 666                         (i.bc == _invokespecial || i.bc == _invokestatic) &&
 667                         e.tagMatches(CONSTANT_InterfaceMethodref) &&
 668                         clsVersion.greaterThan(Constants.JAVA7_MAX_CLASS_VERSION)) {
 669                     match = true;
 670                 }
 671                 if (!match) {
 672                     String message = "illegal reference, expected type="
 673                             + ConstantPool.tagName(tag) + ": "
 674                             + i.toString(cpMap);
 675                     throw new FormatException(message);
 676                 }
 677             }
 678             i = i.next();
 679         }
 680     }
 681     static class FormatException extends IOException {
 682         @java.io.Serial
 683         private static final long serialVersionUID = 3175572275651367015L;
 684 
 685         FormatException(String message) {
 686             super(message);
 687         }
 688     }
 689 }
< prev index next >