summary refs log tree commit diff stats
path: root/tests/enum/tenum_invalid.nim
Commit message (Collapse)AuthorAgeFilesLines
* Don't try and get enum value if its invalid (#22997)Jake Leahy2023-11-281-0/+8
Currently running `nimsuggest`/`check` on this code causes the compiler to raise an exception ```nim type Test = enum A = 9.0 ``` ``` assertions.nim(34) raiseAssert Error: unhandled exception: int128.nim(69, 11) `arg.sdata(3) == 0` out of range [AssertionDefect] ``` Issue was the compiler still trying to get the ordinal value even if it wasn't an ordinal