// or_test: and_test ('or' and_test)* private Expression ParseOrTest() { Expression ret = ParseAndTest(); while (MaybeEat(TokenKind.KeywordOr)) { var start = ret.StartIndex; ret = new OrExpression(ret, ParseAndTest()); ret.SetLoc(_globalParent, start, GetEnd()); } return ret; }
// or_test: and_test ('or' and_test)* private Expression ParseOrTest() { Expression ret = ParseAndTest(); while (MaybeEat(TokenKind.KeywordOr)) { SourceLocation start = ret.Start; ret = new OrExpression(ret, ParseAndTest()); ret.SetLoc(start, GetEnd()); } return ret; }