Пример #1
0
 public CodeBodyParser(TokenStream<String> tokens, CodeBody body, SymbolTable symbols, ASTNode containingNode, MessageLog log = null)
 {
     Log = log ?? new MessageLog();
     Symbols = symbols;
     Tokens = tokens;
     _loopCount = 0;
     _switchCount = 0;
     Node = containingNode;
     Body = body;
     OuterClassScope = NodeUtils.GetOuterClassScope(containingNode);
     // TODO: refactor a better solution to this mess
     if (IsState)
         NodeVariables = (containingNode as State);
     else if (IsFunction)
         NodeVariables = (containingNode as Function);
     else if (IsOperator)
         NodeVariables = (containingNode as OperatorDeclaration);
 }
Пример #2
0
 public ClassOutlineParser(TokenStream<String> tokens, MessageLog log = null)
 {
     Log = log ?? new MessageLog();
     Tokens = tokens;
 }
Пример #3
0
 public ClassValidationVisitor(MessageLog log, SymbolTable symbols)
 {
     Log = log;
     Symbols = symbols;
     Success = true;
 }