Examples of ArgRef


Examples of org.antlr.v4.codegen.model.chunk.ArgRef

  public void attr(String expr, Token x) {
    gen.g.tool.log("action-translator", "attr "+x);
    Attribute a = node.resolver.resolveToAttribute(x.getText(), node);
    if ( a!=null ) {
      switch ( a.dict.type ) {
        case ARG: chunks.add(new ArgRef(nodeContext,x.getText())); break;
        case RET: chunks.add(new RetValueRef(rf.ruleCtx, x.getText())); break;
        case LOCAL: chunks.add(new LocalRef(nodeContext,x.getText())); break;
        case PREDEFINED_RULE: chunks.add(getRulePropertyRef(x))break;
      }
    }
View Full Code Here

Examples of org.antlr.v4.codegen.model.chunk.ArgRef

      chunks.add(new ActionText(nodeContext, "."+y.getText()));
      return;
    }
    Attribute a = node.resolver.resolveToAttribute(x.getText(), y.getText(), node);
    switch ( a.dict.type ) {
      case ARG: chunks.add(new ArgRef(nodeContext,y.getText())); break; // has to be current rule
      case RET:
        if ( factory.getCurrentRuleFunction()!=null &&
          factory.getCurrentRuleFunction().name.equals(x.getText()) )
        {
          chunks.add(new RetValueRef(rf.ruleCtx, y.getText())); break;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.