summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorringabout <43030857+ringabout@users.noreply.github.com>2024-01-05 18:07:27 +0800
committerGitHub <noreply@github.com>2024-01-05 11:07:27 +0100
commit3dee1a3e4c81448b67b75068fef06a121f320758 (patch)
tree04c67ab671542b86e61d13e37cda3e098739b33a /tests
parent74fa8ed59a15caa2ee91f9e559b37728618c3865 (diff)
downloadNim-3dee1a3e4c81448b67b75068fef06a121f320758.tar.gz
fixes #23139; Cannot get repr of range type of enum (#23164)
fixes #23139
Diffstat (limited to 'tests')
-rw-r--r--tests/metatype/tmetatype_various.nim5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/metatype/tmetatype_various.nim b/tests/metatype/tmetatype_various.nim
index 30169aa1e..45c74432d 100644
--- a/tests/metatype/tmetatype_various.nim
+++ b/tests/metatype/tmetatype_various.nim
@@ -66,3 +66,8 @@ var x: array[8, CTBool[Ct[uint32]]]
 x[0] = (CTBool[Ct[uint32]])(1)
 echo x.repr, " ", typeof(x[0])
 
+block: # bug #23139
+  type Foo = enum a, b
+
+  var x: range[a..b]
+  doAssert (repr x) == "a"