{
throw new TinyVMException("Classfile error: Instruction requiring "
+ "CONSTANT_Fieldref entry got "
+ (pEntry == null? "null" : pEntry.getClass().getName()));
}
ConstantFieldref pFieldEntry = (ConstantFieldref) pEntry;
String className = pFieldEntry.getClass(iCF.getConstantPool()).replace(
'.', '/');
ClassRecord pClassRecord = getClassRecord(className);
if (pClassRecord == null)
{
throw new TinyVMException("Attempt to use a field from a primitive array " +
className + " from class " + iCF.getClassName() + " method " + iFullName);
}
ConstantNameAndType cnat = (ConstantNameAndType) iCF.getConstantPool()
.getConstant(pFieldEntry.getNameAndTypeIndex());
String pName = cnat.getName(iCF.getConstantPool());
int pOffset = pClassRecord.getInstanceFieldOffset(pName);
if (pOffset == -1)
{
throw new TinyVMException("Error: Didn't find field " + className