Beispiel #1
0
 def createNumericExpr(self, operator, left, right):
     if operator == MINUS_OPERATOR and right is None:
         return ParsedExpr.ParsedUnaryExpr(left)
     cl = self.opMap[operator]
     if type(cl) is types.TupleType:
         return cl[0](cl[1], left, right)
     return cl(left, right)
Beispiel #2
0
def unaryExpr2(self, __stack, __ptr):
    """
    from XPath/XPathBase.bgen.frag, line 634
    unaryExpr: '-' unionExpr
    """
    __val = ParsedExpr.ParsedUnaryExpr(__stack[__ptr + 2])
    return __val