-
Type:
Task
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Optimization
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Implement narrowType for ExpressionCompare with ExpressionCompare::EQ with two operands.
$eq: ["$a", "string"] -> makes it string(S)
$eq: ["$a", 1] -> makes it number(S)
$eq: ["$a", null] -> makes it null|missing.
Whether the equality holds is given by assumeTrue, e.g.
bool equalityHolds = (expr->getOp() == ExpressionCompare::EQ) == assumeTrue;
Note:
- BSON comparison applies (equality to double(1) will match int(1), so that should just become the number(S) type)
- depends on
-
SERVER-135983 Implement inference for ExpressionConstant and ExpressionFieldPath
-
- Needs Scheduling
-