Example #1
0
 public ParserChar(char c, SrcLoc location = null)
 {
     Value    = c;
     Location = location == null
         ? SrcLoc.Null
         : location;
 }
 public ParserChar(char c, SrcLoc location = null)
 {
     Value = c;
     Location = location == null
         ? SrcLoc.Null
         : location;
 }
Example #3
0
 public ParserError(string expected, ImmutableList <ParserChar> input, string message = "")
 {
     Message  = message;
     Expected = expected;
     Input    = input;
     if (input.IsEmpty)
     {
         Location = SrcLoc.EndOfSource;
     }
     else
     {
         Location = input.Head().Location;
     }
 }
 public ParserError(string expected, ImmutableList<ParserChar> input, string message = "")
 {
     Message = message;
     Expected = expected;
     Input = input;
     if (input.IsEmpty)
     {
         Location = SrcLoc.EndOfSource;
     }
     else
     {
         Location = input.Head().Location;
     }
 }
Example #5
0
 public static ParserChar ParserChar(char c, SrcLoc location = null)
 {
     return(new ParserChar(c, location));
 }