From f4147d5fea31438cfee3dc3781806a1a0b6c40c9 Mon Sep 17 00:00:00 2001 From: Li Jin Date: Thu, 14 Jul 2022 14:35:58 +0800 Subject: fix a case when doing optional destructuring for metatable. --- spec/inputs/switch.yue | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'spec') diff --git a/spec/inputs/switch.yue b/spec/inputs/switch.yue index 04bb02e..9e7ecfd 100644 --- a/spec/inputs/switch.yue +++ b/spec/inputs/switch.yue @@ -144,5 +144,10 @@ do else "should not reach here unless it is not a table" +do + switch y + when {x: #:mt} + print mt + nil -- cgit v1.2.3-55-g6feb