Esempio n. 1
0
        public ParserResult Parse(SourceBuffer buffer)
        {
            var p = new Parser(new Scanner(buffer));

            p.Parse();
            return(new ParserResult(p.Program, p.errors.ErrorList.Count == 0, p.errors.ErrorList));
        }
Esempio n. 2
0
 public Scanner(Stream s)
 {
     using (var sr = new StreamReader(s))
         buffer = new Buffer(sr.ReadToEnd());
     Init();
 }
Esempio n. 3
0
 public Scanner(SourceBuffer buffer)
 {
     this.buffer = buffer;
     Init();
 }