Files
Nim/tests/enum/tredefinition.nim
ringabout 81b7f9108f fixes #21207; reports redefinition error in the definition of enums (#21217)
* fixes #21207;  reports redefinition in the enums

* add a test
2023-01-03 08:15:10 +01:00

9 lines
229 B
Nim

discard """
cmd: '''nim check --hints:off $file'''
action: reject
nimout: '''
tredefinition.nim(9, 25) Error: redefinition of 'Key_a'; previous declaration here: tredefinition.nim(9, 18)
'''
"""
type Key* = enum Key_A, Key_a