File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change @@ -1108,6 +1108,40 @@ switch c {
11081108 (expression_statement
11091109 (number)))))))
11101110
1111+ ================================================================================
1112+ Switch of lazy patterns
1113+ ================================================================================
1114+
1115+ switch c {
1116+ | lazy(r) => r
1117+ | (lazy (), lazy 3) => false
1118+ }
1119+
1120+ --------------------------------------------------------------------------------
1121+
1122+ (source_file
1123+ (expression_statement
1124+ (switch_expression
1125+ (value_identifier)
1126+ (switch_match
1127+ (lazy_pattern
1128+ (parenthesized_pattern
1129+ (value_identifier)))
1130+ (sequence_expression
1131+ (expression_statement
1132+ (value_identifier))))
1133+ (switch_match
1134+ (tuple_pattern
1135+ (tuple_item_pattern
1136+ (lazy_pattern
1137+ (unit)))
1138+ (tuple_item_pattern
1139+ (lazy_pattern
1140+ (number))))
1141+ (sequence_expression
1142+ (expression_statement
1143+ (false)))))))
1144+
11111145================================================================================
11121146Math operators
11131147================================================================================
You can’t perform that action at this time.
0 commit comments