From 117a19d032b887d276103fe5c90c2062cb0a6349 Mon Sep 17 00:00:00 2001 From: ringabout <43030857+ringabout@users.noreply.github.com> Date: Wed, 2 Nov 2022 19:25:51 +0800 Subject: [PATCH] closes #13618; add testcase (#20734) --- tests/typerel/tsigmatch.nim | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 tests/typerel/tsigmatch.nim diff --git a/tests/typerel/tsigmatch.nim b/tests/typerel/tsigmatch.nim new file mode 100644 index 000000000..7541f2028 --- /dev/null +++ b/tests/typerel/tsigmatch.nim @@ -0,0 +1,6 @@ +block: # bug #13618 + proc test(x: Natural or BackwardsIndex): int = + int(x) + + doAssert test(^1) == 1 + doAssert test(1) == 1