예제 #1
0
 public RegexTokenizer(string regex, Token.TokenType type, string name, CharRange?first = null, Token.TokenType previousType = Token.TokenType.NA, params string[] previousNames)
 {
     Regex = new Regex("^" + regex);
     First = first ?? new CharRange {
         Min = char.MinValue, Max = char.MaxValue
     };
     Type          = type;
     Name          = name;
     PreviousType  = previousType;
     PreviousNames = previousNames;
 }