示例#1
0
        public TreeFunctional(string name, TokenType type, int startPos, int endPos)
        {
            this.name = name;
            Token token;

            switch (type)
            {
            case TokenType.FUNCTION:
                token = new TokenFunction(null, startPos, endPos);
                break;

            case TokenType.IF:
                token = new TokenIfElse(startPos, endPos, TokenType.IF);
                break;

            default:
                token = null;
                break;
            }

            this.head          = token;
            this.next          = null;
            this.stackVariable = new Dictionary <string, TokenVariable>();
        }
示例#2
0
 public TreeFunctional()
 {
     this.name = null;
     this.head = null;
     this.next = null;
 }