-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Description
The manual states here http://nim-lang.org/manual.html#enumeration-types :
type
TokenType = enum
a = 2, b = 4, c = 89 # holes are validHowever, it is then not an ordinal anymore, so it is not possible to use these enums as an index type for arrays. The procedures inc, dec, succ and pred are not available for them either.
But I can iterate over this:
for i in TokenType.low .. TokenType.high:
echo iEither the documentation should be updated or the implementation fixed.
Metadata
Metadata
Assignees
Labels
No labels