Beispiel #1
0
 public override Node Clone()
 {
     Module[] modules = new Module[_modules.Length];
     for (int i = 0; i < modules.Length; i++)
         modules[i] = (Module) _modules[i].Clone();
     return new Program(this.Cursor.File, modules, this.Settings);
 }
Beispiel #2
0
        public Program(string name, Module[] modules, Settings settings)
            : base(NodeKind.Program, new Cursor(name))
        {
            _modules = modules;
            foreach (Module module in _modules)
                module.Above = this;

            _settings = settings;
        }
 public override object Visit(Module that, object value = null)
 {
     that.Block.Visit(this);
     return null;
 }
Beispiel #4
0
        public override object Visit(Module that, object value)
        {
            _writer.WriteLine("#** \\file {0}", that.Cursor.File);

            that.Block.Visit(this);
            return null;
        }
        public override object Visit(Module that, object value = null)
        {
            PrintPrologue(that);
            PrintNodeId("Block", that.Block);
            PrintEpilogue(that);

            that.Block.Visit(this);

            return null;
        }
Beispiel #6
0
        public override object Visit(Module that, object value)
        {
            _writer.WriteLine("; Module: {0}", that.Cursor.File);
            _writer.WriteLine();

            that.Block.Visit(this, (object) true);
            return null;
        }