Esempio n. 1
0
 public virtual void VisitAttribute(PragmaAttribute pragma)
 {
     if (pragma.Arguments != null && pragma.Arguments.Length != 0)
     {
         foreach (var arg in pragma.Arguments)
         {
             arg.Accept(this);
         }
     }
 }
Esempio n. 2
0
        PragmaAttribute _Pragma()
        {
            Expect(Pragma);
            var s = new PragmaAttribute { Location = t.Location };
            if (Expect(OpenParenthesis))
            {
                if (Expect(Identifier))
                    s.Identifier = t.Value;

                var l = new List<IExpression>();
                while (laKind == Comma)
                {
                    Step();
                    l.Add(AssignExpression());
                }
                if (l.Count > 0)
                    s.Arguments = l.ToArray();
                Expect (CloseParenthesis);
            }
            s.EndLocation = t.EndLocation;
            return s;
        }
 public virtual void VisitAttribute(PragmaAttribute pragma)
 {
     if (pragma.Arguments != null && pragma.Arguments.Length != 0)
         foreach (var arg in pragma.Arguments)
             arg.Accept(this);
 }
Esempio n. 4
0
        PragmaAttribute _Pragma()
        {
            Expect(Pragma);
            var s = new PragmaAttribute();
            LastParsedObject = s;
            if (Expect(OpenParenthesis))
            {
                if (Expect(Identifier))
                    s.Identifier = t.Value;

                var l = new List<IExpression>();
                while (laKind == Comma)
                {
                    Step();
                    l.Add(AssignExpression());
                }
                if (l.Count > 0)
                    s.Arguments = l.ToArray();

                if (Expect(CloseParenthesis))
                    TrackerVariables.ExpectingIdentifier = false;
            }
            return s;
        }
 public override void VisitAttribute(PragmaAttribute a)
 {
     if (a.Arguments != null &&
         a.Arguments.Length>0 &&
         IsIncompleteExpression (a.Arguments[a.Arguments.Length-1])) {
         prv = new AttributeCompletionProvider (cdgen) { Attribute=a };
         halt = true;
     }
     else
         base.VisitAttribute (a);
 }
		public PragmaCompletionProvider(PragmaAttribute attr,ICompletionDataGenerator gen) : base(gen) {
			Attribute = attr;
		}