[SERVER-70611] [SBE] Revisit expected semantics of non-boolean values for EPrimBinary and/or Created: 17/Oct/22  Updated: 05/Dec/22

Status: Backlog
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Major - P3
Reporter: Mihai Andrei Assignee: Backlog - Query Execution
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Query Execution
Participants:

 Description   

The expected behavior around non-boolean values for EPrimBinary and/or is unclear. Though higher-level logic can enforce that the expected values are boolean (for instance, by building an expression which type checks before calling into binary and/or), it's not clear what the behavior of the instructions themselves should be. For example, suppose we are executing EPrimBinary::and(17, true). Should we: 

  • Treat 17 as truthy and evaluate the constant true?
  • Treat 17 as a non-bool value and return nothing?
  • Expect undefined behavior? 

This ticket tracks the work to not only decide on the "expected" semantics, but also to implement them.



 Comments   
Comment by Ana Meza [ 25/Oct/22 ]

mihai.andrei@mongodb.com could you please join next Triage meeting so we can discuss this one further

Generated at Thu Feb 08 06:16:37 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.