Esempio n. 1
0
        static void Main(string[] args)
        {
            var l = new LexAnalyzer();
            l.Parse("a>14 and not not (a=0x23) and b=12 and c=HELLO");
            var ll = new LLAnalyzer<Element>(l, new Finder());
            var expr = ll.Analyze();
            Console.WriteLine(expr);
            Console.WriteLine(expr.TestValidity(new Element()) ? "true" : "false");

            Console.ReadKey();
        }
Esempio n. 2
0
 /// <summary>
 /// Create new syntactic analyzer
 /// </summary>
 /// <param name="lex">Lexical analyzer output</param>
 /// <param name="finder">Table with information about variables</param>
 public LLAnalyzer(LexAnalyzer lex, IPropertyFinder finder)
 {
     this.finder     = finder;
     this.TokenQueue = lex.Tokens;
     CreateInputQueue();
 }