A constant pool entry of kind CONSTANT_Methodref should refer to a method in a class type, while a constant pool entry of kind CONSTANT_InterfaceMethodref should refer to a method in an interface type. Historically, the spec of these two constant pool kinds was strict about this. Notice the two "must be" clauses in the following:
-----
class_index
The value of the class_index item must be a valid index into the constant_pool table. The constant_pool entry at that index must be a CONSTANT_Class_info structure (ยง4.4.1) representing a class or interface type that has the field or method as a member.
In a CONSTANT_Fieldref_info structure, the class_index item may be either a class type or an interface type.
In a CONSTANT_Methodref_info structure, the class_index item *****must be***** a class type, not an interface type.
In a CONSTANT_InterfaceMethodref_info structure, the class_index item *****must be***** an interface type, not a class type.
-----
Checking that the class_index item of a constant pool entry actually refers to a class type rather than an interface type (or vice versa) requires eager loading of the referenced type, in particular during format checking of the class which contains the constant pool entry.
This eagerness is at odds with the laziness of resolution for symbolic references derived from constant pool entries. In addition, the rules of resolution already take ownership of the class-versus-interface question, in 5.4.3.3 ("If C is an interface, method resolution throws an IncompatibleClassChangeError.") and 5.4.3.4 ("If C is not an interface, interface method resolution throws an IncompatibleClassChangeError.").
Accordingly, the 4.4.2 text for class_index should be relaxed so that, during format checking, no ClassFormatError is due if the wrong kind of class/interface type is referenced:
-----
In a CONSTANT_Methodref_info structure, the class_index item *****should be***** a class type, not an interface type.
In a CONSTANT_InterfaceMethodref_info structure, the class_index item *****should be***** an interface type, not a class type.
-----