Package dtool.ast.definitions

Examples of dtool.ast.definitions.Symbol


  public NodeResult<AttribPragma> parseAttribPragma() {
    if(!tryConsume(DeeTokens.KW_PRAGMA))
      return null;
    ParseHelper parse = new ParseHelper();
   
    Symbol pragmaId = null;
    NodeListView<Expression> expList = null;
   
    parsing: {
      if(parse.consumeRequired(DeeTokens.OPEN_PARENS).ruleBroken) break parsing;
      pragmaId = parseIdSymbol();
View Full Code Here


    Reference baseRef = null;
    NodeListView<Expression> args = null;
   
    if(lookAhead() == DeeTokens.IDENTIFIER && DeeTokenSemantics.isPredefinedAttribId(lookAheadElement())) {
      BaseLexElement traitsId = consumeLookAhead(DeeTokens.IDENTIFIER);
      Symbol attribIdentifier = conclude(srOf(traitsId, new Symbol(traitsId.getSourceValue())));
      return parse.resultConclude(new AttribAtKeyword(attribIdentifier));
    }
   
    parsing: {
      baseRef = attemptParseRefIdentifier();
View Full Code Here

  public final Symbol parseIdSymbol() {
    BaseLexElement token = consumeExpectedContentToken(DeeTokens.IDENTIFIER);
    return createIdSymbol(token);
  }
  public final Symbol createIdSymbol(BaseLexElement token) {
    return conclude(token.getMissingError(), srOf(token, new Symbol(token.getSourceValue())));
  }
View Full Code Here

  protected NodeResult<FunctionBodyOutBlock> parseOutBlock() {
    if(!tryConsume(DeeTokens.KW_OUT))
      return nullResult();
    ParseHelper parse = new ParseHelper();
   
    Symbol id = null;
    BlockStatement block = null;
   
    parsing: {
      if(parse.consumeOptional(DeeTokens.OPEN_PARENS)) {
        id = parseIdSymbol();
View Full Code Here

  public NodeResult<ExpTraits> parseTraitsExpression() {
    if(!tryConsume(DeeTokens.KW___TRAITS))
      return null;
    ParseHelper parse = new ParseHelper();
   
    Symbol traitsId = null;
    NodeListView<Resolvable> args = null;
   
    parsing: {
      if(parse.consumeRequired(DeeTokens.OPEN_PARENS).ruleBroken) break parsing;
     
View Full Code Here

  }
 
  public Symbol parseTraitsId() {
    BaseLexElement traitsId = consumeExpectedContentToken(DeeTokens.IDENTIFIER);
    ParserError error = DeeTokenSemantics.checkTraitsId(traitsId);
    return conclude(error, srOf(traitsId, new Symbol(traitsId.getSourceValue())));
  }
View Full Code Here

 
  protected NodeResult<StatementLabel> parseStatementLabel_start() {
    LexElement labelId = consumeLookAhead(DeeTokens.IDENTIFIER);
    consumeLookAhead(DeeTokens.COLON);
   
    Symbol label = createIdSymbol(labelId);
    return resultConclude(false, srBounds(labelId.getStartPos(), getSourcePosition(), new StatementLabel(label)));
  }
View Full Code Here

  public NodeResult<StatementContinue> parseStatementContinue() {
    if(!tryConsume(DeeTokens.KW_CONTINUE))
      return nullResult();
    ParseHelper parse = new ParseHelper();
   
    Symbol id = lookAhead() == DeeTokens.IDENTIFIER ? parseIdSymbol() : null;
    parse.consumeRequired(DeeTokens.SEMICOLON);
   
    return parse.resultConclude(new StatementContinue(id));
  }
View Full Code Here

  public NodeResult<StatementBreak> parseStatementBreak() {
    if(!tryConsume(DeeTokens.KW_BREAK))
      return nullResult();
    ParseHelper parse = new ParseHelper();
   
    Symbol id = lookAhead() == DeeTokens.IDENTIFIER ? parseIdSymbol() : null;
    parse.consumeRequired(DeeTokens.SEMICOLON);
   
    return parse.resultConclude(new StatementBreak(id));
  }
View Full Code Here

    if(tryConsume(DeeTokens.KW_DEFAULT)) {
      parse.consumeRequired(DeeTokens.SEMICOLON);
      return parse.resultConclude(new StatementGotoDefault());
    }
   
    Symbol label = parseIdSymbol();
    parse.consumeRequired(DeeTokens.SEMICOLON);
    return parse.resultConclude(new StatementGoto(label));
  }
View Full Code Here

TOP

Related Classes of dtool.ast.definitions.Symbol

Copyright © 2018 www.massapicom. 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.