Beispiel #1
0
        public override object Visit(GuardStatement that, object value)
        {
            _writer.Write("guard ");
            _writer.Write(BackquoteNameOpt(that.Name.Symbol));
            _writer.Write(" is ");
            _writer.Write(ToString(that.Direction));
            that.Type.Visit(this);

            if (that.Getter != null || that.Setter != null)
                _writer.WriteLine(':');

            _writer.Indent();
            if (that.Getter != null)
                that.Getter.Visit(this);
            if (that.Setter != null)
                that.Setter.Visit(this);
            _writer.Dedent();
            return null;
        }
        public override object Visit(GuardStatement that, object value = null)
        {
            PrintPrologue(that);
            PrintDefinition(that);
            PrintNodeId("Type", that.Type);
            PrintNodeId("Getter", that.Getter);
            PrintNodeId("Setter", that.Setter);
            PrintEpilogue(that);

            that.Name.Visit(this);
            that.Type.Visit(this);
            that.Getter.Visit(this);
            that.Setter.Visit(this);

            return null;
        }
 public override object Visit(GuardStatement that, object value = null)
 {
     _symbols.EnterBlock(that.Name.Symbol, that);
     that.Getter.Visit(this);
     that.Setter.Visit(this);
     _symbols.LeaveBlock(that.Name.Symbol);
     return null;
 }
Beispiel #4
0
 public override object Visit(GuardStatement that, object value)
 {
     if (that.Direction == DirectionKind.InOut || that.Direction == DirectionKind.Out)
         that.Getter.Visit(this);
     if (that.Direction == DirectionKind.In || that.Direction == DirectionKind.InOut)
         that.Setter.Visit(this);
     return null;
 }
Beispiel #5
0
 public virtual object Visit(GuardStatement that, object value)
 {
     throw new System.NotImplementedException();
 }