diff --git a/pymbolic/primitives.py b/pymbolic/primitives.py index 49db90b60019f734a5e6dd593e57c805a6d4addb..f194874aec4cbeb28a511116548cc97671f07c6d 100644 --- a/pymbolic/primitives.py +++ b/pymbolic/primitives.py @@ -86,6 +86,8 @@ class Expression(object): if not is_valid_operand(other): return NotImplemented + if is_zero(other): + return 0 return quotient(other, self) __rtruediv__ = __rdiv__