Store IncrementalRolloutFeatureFlag pointers as non-const

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Execution
    • QE 2025-12-08
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      getMutableAllIncrementalRolloutFeatureFlags() stores pointers as const IncrementalRolloutFeatureFlag*, but findByName() needs to return a mutable pointer, requiring a const_cast. This pattern is backwards; we should store mutable and expose const, not store const and cast it away.

      1. Change the internal vector to store non-const IncrementalRolloutFeatureFlag*
      2. Change getAll() to return a reinterpret_cast const view
      3. Remove const_cast in findByName()

            Assignee:
            Niels Lohmann
            Reporter:
            Daniel Segel
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: