Beispiel #1
0
 public DefineNode(NameExpression name, IEnumerable<NameExpression> arguments, INode body, ScopeMode mode)
 {
     this.arguments = new List<NameExpression> (arguments);
     this.body = body;
     this.mode = mode;
     this.name = name;
 }
Beispiel #2
0
 public ForNode(IExpression from, NameExpression key, NameExpression value, INode body, INode empty)
 {
     this.body = body;
     this.empty = empty;
     this.from = from;
     this.key = key;
     this.value = value;
 }
Beispiel #3
0
        private NameExpression ParseName()
        {
            NameExpression  name;

            if (this.lexer.Current.Type != LexemType.Literal)
                throw new UnexpectedException (this.lexer, "variable name");

            name = new NameExpression (this.lexer.Current.Content);

            this.lexer.Next (LexerMode.BLOCK);

            return name;
        }
Beispiel #4
0
 public SetNode(NameExpression name, IExpression expression, ScopeMode mode)
 {
     this.expression = expression;
     this.mode = mode;
     this.name = name;
 }