예제 #1
0
파일: Program.cs 프로젝트: bencz/Beryl
 public Program(Position position, LetCommand command)
     : base(position)
 {
     _command = command;
     _command.Parent = this;
 }
예제 #2
0
 public Program(Position position, LetCommand command) :
     base(position)
 {
     _command        = command;
     _command.Parent = this;
 }
예제 #3
0
파일: CodeGen.cs 프로젝트: bencz/Beryl
 public void visit(LetCommand that)
 {
     Console.WriteLine("{");
     // note: function declarations should be output before the first line
     foreach (Declaration declaration in that.Declarations)
         declaration.visit(this);
     that.Command.visit(this);
     Console.WriteLine("}");
 }
예제 #4
0
파일: Checker.cs 프로젝트: bencz/Beryl
 public void visit(LetCommand that)
 {
     string name = CreateName();
     _symbols.EnterScope(name);
     foreach (Declaration declaration in that.Declarations)
         declaration.visit(this);
     that.Command.visit(this);
     _symbols.LeaveScope(name);
 }