MCPcopy Index your code
hub / github.com/antlr/codebuff / super_new

Method super_new

output/java8/1.4.13/Interpreter.java:452–468  ·  view source on GitHub ↗
(InstanceScope scope, String name, int nargs)

Source from the content-addressed store, hash-verified

450 // TODO: refactor to remove dup'd code
451
452 void super_new(InstanceScope scope, String name, int nargs) {
453 final ST self = scope.st;
454 ST st = null;
455 CompiledST imported = self.impl.nativeGroup.lookupImportedTemplate(name);
456 if ( imported==null ) {
457 errMgr.runTimeError(this, scope, ErrorType.NO_IMPORTED_TEMPLATE, name);
458 st = self.groupThatCreatedThisInstance.createStringTemplateInternally(new CompiledST());
459 }
460 else {
461 st = imported.nativeGroup.getEmbeddedInstanceOf(this, scope, name);
462 st.groupThatCreatedThisInstance = group;
463 }
464 // get n args and store into st's attr list
465 storeArgs(scope, nargs, st);
466 sp -= nargs;
467 operands[++sp] = st;
468 }
469
470 void super_new(InstanceScope scope, String name, Map<String, Object> attrs) {
471 final ST self = scope.st;

Callers 1

_execMethod · 0.95

Calls 5

storeArgsMethod · 0.95
runTimeErrorMethod · 0.65
getEmbeddedInstanceOfMethod · 0.45

Tested by

no test coverage detected