SERVER-139105In Code Review

IDL enums should expose a generated list of all their values

IDL generates C++ enums with serialize and deserialize helpers, but gives no way to iterate over their values. Any code that needs every enumerator, such as an exhaustive test, has to keep a hand-written list that can drift from the {{.idl}} file. This came up in review of SERVER-137418. The recipient transition validation test checks every {{(from, to)}} pair of {{RecipientStateEnum}} against the edge table. To do that it keeps two hand-maintained pieces: * {{{}allStates{}}}, an array of a

Affected Versions
Versions known to exhibit this issue

No affected versions recorded.

Fixed Versions
Versions that include the fix
9.1.0-rc09.1.0-rc1025
Components
Server components related to this issue

No components specified.

Labels
Tags and classification
repo-10gen-mongosage-autosp-infinite-burndown