Lines Matching refs:operator
115 def __init__(self, operator: str, lhs: Union[int, float, Expression],
117 self.operator = operator
145 if _PRECEDENCE.get(self.operator, -1) > _PRECEDENCE.get(
146 other.operator, -1):
148 if rhs and _PRECEDENCE.get(self.operator, -1) == _PRECEDENCE.get(
149 other.operator, -1):
165 return Constant(ast.literal_eval(lhs + self.operator + rhs))
168 if self.operator in ('+', '|') and lhs.value == '0':
173 if self.operator == '*' and lhs.value == '0' and (
177 if self.operator == '*' and lhs.value == '1':
181 if self.operator in ('+', '|') and rhs.value == '0':
184 if self.operator == '*' and rhs.value == '0':
187 if self.operator == '*' and self.rhs.value == '1':
190 return Operator(self.operator, lhs, rhs)
194 return self.operator == other.operator and self.lhs.Equals(
205 return Operator(self.operator, lhs, rhs)