private void installClass(CgenNode nd) { AbstractSymbol name = nd.getName(); if (probe(name) != null) return; nds.addElement(nd); nodeMap.put(nd.getName(), nd); addId(name, nd); }
private void codeObjInits() { str.println("\n# Object Initializers"); for (Object obj : nds) { CgenNode nd = (CgenNode) obj; // code object initailzers (constructor method) CgenSupport.emitInitRef(nd.getName(), str); str.print(CgenSupport.LABEL); nd.codeObjInit(str); } }
private void codeDispTables() { str.println("\n# Dispatch Tables"); for (Object obj : nds) { CgenNode nd = (CgenNode) obj; // code class method reference CgenSupport.emitDispTableRef(nd.getName(), str); str.print(CgenSupport.LABEL); nd.codeDispTab(str); } }
private void codeProtObjs() { str.println("\n# Prototype Objects"); for (Object obj : nds) { CgenNode nd = (CgenNode) obj; // code class attributes str.println(CgenSupport.WORD + "-1"); // GC tag CgenSupport.emitProtObjRef(nd.getName(), str); str.print(CgenSupport.LABEL); nd.codeProtObj(str); } }