Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-14128

Add default statement for our switch cases

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Storage Engines

      During our transition to v5 toolchain, it is discovered that some of our switch cases does not have a default statement thus producing warnings like:

      /data/mci/c42db90c3cc587595fc36b0d48cfef5d/wiredtiger/src/include/cell_inline.h:594:5: warning: 'switch' missing 'default' label [-Wswitch-default]
      594 |     switch (WT_CELL_SHORT_TYPE(cell->__chunk[0])) {
          |     ^ 

      We are adding an ignore flag for this warning in  WT-14121. However, in the long term, we want to ensure that our switch cases include default statements.

      The goal of this ticket is to compile WiredTiger without the -Wswitch-default ignore flag and resolve any warnings related to missing default cases in switch statements.

            Assignee:
            backlog-server-storage-engines [DO NOT USE] Backlog - Storage Engines Team
            Reporter:
            jasmine.bi@mongodb.com Jasmine Bi
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: