def RelationalExpr(self): AdditiveExpr = self.AdditiveExpr() Expr = AdditiveExpr while self._peek('REL_COMP', 'EQ_COMP', "r'and'", "r'or'", 'END', "r'\\]'", "r'\\)'", "r'\\,'") == 'REL_COMP': REL_COMP = self._scan('REL_COMP') AdditiveExpr = self.AdditiveExpr() Expr = X.EqualityExpr(REL_COMP, Expr, AdditiveExpr) return Expr
def EqualityExpr(self): RelationalExpr = self.RelationalExpr() Expr = RelationalExpr while self._peek('EQ_COMP', "r'and'", "r'or'", 'END', "r'\\]'", "r'\\)'", "r'\\,'") == 'EQ_COMP': EQ_COMP = self._scan('EQ_COMP') RelationalExpr = self.RelationalExpr() Expr = X.EqualityExpr(EQ_COMP, Expr, RelationalExpr) return Expr