示例#1
0
文件: LexInput.cs 项目: zanedp/Nett
        public static string Consume(this LexInput input, int len)
        {
            var sb = new StringBuilder(len);

            for (int i = 0; i < len; i++)
            {
                sb.Append(input.Consume());
            }

            return(sb.ToString());
        }
示例#2
0
文件: Lexer.cs 项目: firleju/Nett
 public Lexer(string input)
 {
     this.input      = new LexInput(input, this.LexLValue, this.LexRValue);
     this.lexerState = this.input.LexValueState;
 }