Add helpers to SBE ByteCode that return TagValue{Maybe}Owned

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 9.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Execution
    • Fully Compatible
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      ByteCode currently has viewFromStack(N) which returns TagValueView, but moveFromStack(N) still returns a raw FastTuple<bool, TypeTags, Value>. This forces call sites to wrap the result manually:

      auto x = TagValueMaybeOwned::fromRaw(moveFromStack(0));
      

      Add a moveOwnedFromStack(N) method that returns TagValueMaybeOwned directly, completing the RAII accessor trio:

      • viewFromStack(N)TagValueView (non-owning peek)
      • moveOwnedFromStack(N)TagValueMaybeOwned (ownership transfer)

      Then sweep all call sites in vm_builtin*.cpp and vm_block.cpp that use the fromRaw(moveFromStack(...)) pattern and replace with moveOwnedFromStack(...).

            Assignee:
            Evan Bergeron
            Reporter:
            Mihai Andrei
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: