VM_TypeReference tRef; if (className == null) {    try { is.mark(is.available()); tRef = getClassTypeRef(new DataInputStream(is), classloader); is.reset(); } catch (IOException e) { ClassFormatError cfe = new ClassFormatError(e.getMessage()); cfe.initCause(e); throw cfe; } } else { VM_Atom classDescriptor = VM_Atom.findOrCreateAsciiAtom(className.replace('.','/')).descriptorFromClassName(); tRef = VM_TypeReference.findOrCreate(classloader, classDescriptor); }  try { if (VM.VerifyAssertions) VM._assert(tRef.isClassType()); if (VM.TraceClassLoading  && VM.runningVM) VM.sysWriteln("loading \"" + tRef.getName() + "\" with " + classloader); VM_Class ans = new VM_Class(tRef, new DataInputStream(is)); tRef.setResolvedType(ans); return ans; } catch (IOException e) { ClassFormatError cfe = new ClassFormatError(e.getMessage()); cfe.initCause(e); throw cfe; }
return defineClassInternal(className, new ByteArrayInputStream(classRep, offset, length), classloader);
  public static final VM_Type defineClassInternal(String className,                                                   InputStream is,                                                   ClassLoader classloader) throws ClassFormatError {    VM_TypeReference tRef;    if (className == null) {      // NUTS: Our caller hasn't bothered to tell us what this class is supposed      //       to be called, so we must read the input stream and discover it overselves      //       before we actually can create the VM_Class instance.      try {        is.mark(is.available());        tRef = getClassTypeRef(new DataInputStream(is), classloader);        is.reset();      } catch (IOException e) {        ClassFormatError cfe = new ClassFormatError(e.getMessage());        cfe.initCause(e);        throw cfe;      }    } else {      VM_Atom classDescriptor = VM_Atom.findOrCreateAsciiAtom(className.replace('.','/')).descriptorFromClassName();      tRef = VM_TypeReference.findOrCreate(classloader, classDescriptor);    }    try {      if (VM.VerifyAssertions) VM._assert(tRef.isClassType());      if (VM.TraceClassLoading  && VM.runningVM)        VM.sysWriteln("loading \"" + tRef.getName() + "\" with " + classloader);      VM_Class ans = new VM_Class(tRef, new DataInputStream(is));      tRef.setResolvedType(ans);      return ans;    } catch (IOException e) {      ClassFormatError cfe = new ClassFormatError(e.getMessage());      cfe.initCause(e);      throw cfe;    }  }