Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-80870

[CQF] Improvements to If constant folding

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.2.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Optimization
    • Fully Compatible

      Perform the following foldings:

       

      1. If (expression) ? true : false -> (expression)

      2. if (expression) ? false : true -> NOT (expression)

      3. if (expr1) ? true  true -> true

      4. if (expr1) ? false : false -> false

      5. if (not (expr1)) ? expr2 : expr3 -> if (expr1) ? expr3 : expr2.

            Assignee:
            svilen.mihaylov@mongodb.com Svilen Mihaylov (Inactive)
            Reporter:
            svilen.mihaylov@mongodb.com Svilen Mihaylov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: