Пример #1
0
 public override void ResolveNames(LexicalScope scope)
 {
     if (this.exp != null)
     {
         this.exp.ResolveNames(scope);
     }
 }
Пример #2
0
        public override void ResolveNames(LexicalScope scope)
        {
            this.AddToSymbolTable(scope);

            foreach (LocalVariable localVariable in this.localVariables)
            {
                localVariable.ResolveNames(scope);
            }
        }
Пример #3
0
        public override void ResolveNames(LexicalScope scope)
        {
            this.symboltable = new LexicalScope(scope);

            foreach (Statement statement in this.statements)
            {
                statement.ResolveNames(this.symboltable);
            }
        }
Пример #4
0
        public override void ResolveNames(LexicalScope scope)
        {
            this.symboltable = new LexicalScope(scope);

            foreach (Declaration declaration in this.declarations)
            {
                declaration.ResolveNames(this.symboltable);
            }
        }
Пример #5
0
        public override void ResolveNames(LexicalScope scope)
        {
            if (scope != null)
            {
                this.declaration = scope.Resolve(this.name);
            }

            if (this.declaration == null)
            {
                Console.WriteLine("Error : Undefined identifier {0}\n", this.name);
                throw new Exception("Undefined identifier");
            }
        }
Пример #6
0
        public override void ResolveNames(LexicalScope scope)
        {
            this.AddToSymbolTable(scope);
            this.symboltable = new LexicalScope(scope);

            this.result.ResolveNames(this.symboltable);

            foreach (FormalParameter formalParameter in this.formalParameters)
            {
                formalParameter.ResolveNames(this.symboltable);
            }

            this.statement.ResolveNames(this.symboltable);
        }
Пример #7
0
        public override void ResolveNames(LexicalScope scope)
        {
            foreach (Expression fi in this.forinit)
            {
                fi.ResolveNames(scope);
            }

            if (this.exp != null)
            {
                this.exp.ResolveNames(scope);
            }
            foreach (Expression up in this.updates)
            {
                up.ResolveNames(scope);
            }
        }
Пример #8
0
 public override void ResolveNames(LexicalScope scope)
 {
 }
Пример #9
0
 public override void ResolveNames(LexicalScope scope)
 {
     this.lhs.ResolveNames(scope);
     this.rhs.ResolveNames(scope);
 }
Пример #10
0
 public override void AddToSymbolTable(LexicalScope scope)
 {
     scope.Add(className, this);
 }
Пример #11
0
 public abstract void AddToSymbolTable(LexicalScope scope);
Пример #12
0
 public override void AddToSymbolTable(LexicalScope scope)
 {
     scope.Add(this.methodName, this);
 }
Пример #13
0
        public override void ResolveNames(LexicalScope scope)
        {
            this.AddToSymbolTable(scope);

            this.type.ResolveNames(scope);
        }
Пример #14
0
 public override void ResolveNames(LexicalScope scope)
 {
     this.declaration.ResolveNames(scope);
 }
Пример #15
0
 public abstract void ResolveNames(LexicalScope scope);
Пример #16
0
 public LexicalScope(LexicalScope parent)
 {
     this.symbol_table = new Dictionary <string, Declaration>();
     this.parent       = parent;
 }
Пример #17
0
 public override void AddToSymbolTable(LexicalScope scope)
 {
 }