MCPcopy Create free account
hub / github.com/antlr/codebuff / setFirstArgument

Method setFirstArgument

output/java/1.4.15/Interpreter.java:939–952  ·  view source on GitHub ↗
(InstanceScope scope, ST st, Object attr)

Source from the content-addressed store, hash-verified

937 }
938
939 protected void setFirstArgument(InstanceScope scope, ST st, Object attr) {
940 if ( !st.impl.hasFormalArgs ) {
941 if ( st.impl.formalArguments==null ) {
942 st.add(ST.IMPLICIT_ARG_NAME, attr);
943 return;
944 }
945 // else fall thru to set locals[0]
946 }
947 if ( st.impl.formalArguments==null ) {
948 errMgr.runTimeError(this, scope, ErrorType.ARGUMENT_COUNT_MISMATCH, 1, st.impl.name, 0);
949 return;
950 }
951 st.locals[0] = attr;
952 }
953
954 protected void addToList(InstanceScope scope, List<Object> list, Object o) {
955 o = convertAnythingIteratableToIterator(scope, o);

Callers 2

rot_mapMethod · 0.95
rot_map_iteratorMethod · 0.95

Calls 2

addMethod · 0.65
runTimeErrorMethod · 0.65

Tested by

no test coverage detected