[temp.mem.enum] Fix consistency of example with [temp.inst] (editorial) #7558
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The example is inconsistent with [temp.inst] p3, which states the following:
Hence, the example can be fixed by either (1) omitting the instantiation or (2) by replacing the unscoped with a scoped enumeration. Since the implicit instantiation does not contribute to the point of [temp.mem.enum], the inconsistency can be solved most easily with alternative (1).
The example was taken exactly as is from DR1206, where it already seems to be an accidental copy-paste mishap because it is not important for the statement it is trying to make.
If one is willing to assume that, it is just an editorial issue.
Note: the example as is does not compile with any of the major compilers.
See here on Compiler Explorer: https://godbolt.org/z/xjM15MjP8