File tree 1 file changed +3
-4
lines changed
crates/ide_assists/src/handlers 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -1178,13 +1178,12 @@ impl FlowHandler {
1178
1178
let stmt = make:: expr_stmt ( action) ;
1179
1179
let block = make:: block_expr ( iter:: once ( stmt. into ( ) ) , None ) ;
1180
1180
let controlflow_break_path = make:: path_from_text ( "ControlFlow::Break" ) ;
1181
- let tuple_pat = make:: tuple_pat ( iter:: empty ( ) ) ;
1182
1181
let condition = make:: condition (
1183
1182
call_expr,
1184
1183
Some (
1185
1184
make:: tuple_struct_pat (
1186
1185
controlflow_break_path,
1187
- iter:: once ( tuple_pat . into ( ) ) ,
1186
+ iter:: once ( make :: wildcard_pat ( ) . into ( ) ) ,
1188
1187
)
1189
1188
. into ( ) ,
1190
1189
) ,
@@ -3294,7 +3293,7 @@ fn foo() {
3294
3293
fn foo() {
3295
3294
loop {
3296
3295
let mut n = 1;
3297
- if let ControlFlow::Break(() ) = fun_name(&mut n) {
3296
+ if let ControlFlow::Break(_ ) = fun_name(&mut n) {
3298
3297
break;
3299
3298
}
3300
3299
let h = 1 + n;
@@ -3331,7 +3330,7 @@ fn foo() {
3331
3330
fn foo() {
3332
3331
loop {
3333
3332
let mut n = 1;
3334
- if let ControlFlow::Break(() ) = fun_name(n) {
3333
+ if let ControlFlow::Break(_ ) = fun_name(n) {
3335
3334
break;
3336
3335
}
3337
3336
let h = 1;
You can’t perform that action at this time.
0 commit comments