Iterating over it returns each side number in turn. This allows
converting many loops of the form:
```
for (int i = 0; i < MAX_SIDES_PER_SEGMENT; ++i)
```
to the compact form:
```
for (const auto i : MAX_SIDES_PER_SEGMENT)
```
The compact form brings the usual benefit of range-based for: delegating
iteration to the compiler prevents the loop body from skipping a step,
and makes clear in the code that this is the case.
Some flags merit a type other than int8_t. Begin moving flags out to
distinct variables with their own type.
Add static_assert checks that the ABI relevant structures do not change.
clang warns that an implicit copy constructor is deprecated in the
presence of an explicitly defaulted copy-assignment operator.
Add an explicitly defaulted default constructor too, since the
explicitly defaulted copy constructor suppresses generation of an
implicit default constructor, and the default constructor is needed.
If std::common_type<range::index_type>... finds a common index_type
among all the zipped ranges, pass that common type through as
zip<...>::index_type. Otherwise, set zip<...>::index_type to void.
This allows enumerate(zip(...))) to report a better index_type.
enum game_mode_flags must be visible in common code, which does not
define DXX_BUILD_DESCENT_II. To avoid One Definition Rule errors,
game_mode_flags must have the same definition in all files.
Fortunately, the DXX_BUILD_DESCENT_II definition is a superset of the
common definition, so the preprocessor guards can be replaced with
advisory comments.
Fixes: 2b718da343 ("Use enum class for Game_mode, Newdemo_game_mode")
Change it from the level number on which the path was created to a
true/false flag. The previous logic only tested whether the number was
equal to the current level number.
This also fixes a bug where the action was not available on the first
secret level, since that level is `-1`, and the value was set to `-1` to
indicate that it should be enabled.