private static void InternalRunParse(IParseRunner parseRunner) { while (!parseRunner.EndOfStream()) { Assert.IsTrue(parseRunner.Read(), $"Parse Failed at Position {parseRunner.Position}"); } Assert.IsTrue(parseRunner.ParseEngine.IsAccepted(), $"Parse was not accepted"); }
private static bool RunParse(IParseRunner lexer) { while (!lexer.EndOfStream()) { if (!lexer.Read()) { return(false); } } return(lexer.ParseEngine.IsAccepted()); }
private static void InternalRunParse(IParseRunner parseRunner) { while (!parseRunner.EndOfStream()) { if (!parseRunner.Read()) { Assert.Fail($"Parse Failed at Position {parseRunner.Position}"); } } if (!parseRunner.ParseEngine.IsAccepted()) { Assert.Fail($"Parse was not accepted"); } }