From 2e4df27132afafbd9ac5ec14070432c38d6cae8f Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Fri, 18 Jun 2021 22:14:39 +0300 Subject: minor: use minicore --- crates/ide_assists/src/handlers/extract_function.rs | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) (limited to 'crates/ide_assists') diff --git a/crates/ide_assists/src/handlers/extract_function.rs b/crates/ide_assists/src/handlers/extract_function.rs index 43e83d683..ac7f0959b 100644 --- a/crates/ide_assists/src/handlers/extract_function.rs +++ b/crates/ide_assists/src/handlers/extract_function.rs @@ -831,7 +831,6 @@ fn path_element_of_reference( })?; stdx::always!( matches!(path, ast::Expr::PathExpr(_) | ast::Expr::MacroCall(_)), - "unexpected expression type for variable usage: {:?}", path ); @@ -2991,11 +2990,7 @@ mod bar { check_assist( extract_function, r#" -enum Option { - #[lang = "None"] None, - #[lang = "Some"] Some(T), -} -use Option::*; +//- minicore: option fn foo() { loop { let n = 1; @@ -3007,11 +3002,6 @@ fn foo() { } "#, r#" -enum Option { - #[lang = "None"] None, - #[lang = "Some"] Some(T), -} -use Option::*; fn foo() { loop { let n = 1; -- cgit v1.2.3