diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-02-06 16:50:01 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2020-02-06 16:50:01 +0000 |
commit | 895cdb588314f4e04529d1adf8cd232856497dad (patch) | |
tree | 6466cb45c30478eb0c413c25cc6d07cf23d39d3a /crates/ra_assists/src/assists/flip_binexpr.rs | |
parent | 8b957caf83b18b3fea153f770bfd0ed979227eff (diff) | |
parent | d1e8b8d134da802eecef5cbcd5486bd542ad75b5 (diff) |
Merge #3034
3034: Remove ImportLocator hack r=matklad a=matklad
Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_assists/src/assists/flip_binexpr.rs')
-rw-r--r-- | crates/ra_assists/src/assists/flip_binexpr.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/crates/ra_assists/src/assists/flip_binexpr.rs b/crates/ra_assists/src/assists/flip_binexpr.rs index 2074087cd..bfcc09e90 100644 --- a/crates/ra_assists/src/assists/flip_binexpr.rs +++ b/crates/ra_assists/src/assists/flip_binexpr.rs | |||
@@ -1,4 +1,3 @@ | |||
1 | use hir::db::HirDatabase; | ||
2 | use ra_syntax::ast::{AstNode, BinExpr, BinOp}; | 1 | use ra_syntax::ast::{AstNode, BinExpr, BinOp}; |
3 | 2 | ||
4 | use crate::{Assist, AssistCtx, AssistId}; | 3 | use crate::{Assist, AssistCtx, AssistId}; |
@@ -18,7 +17,7 @@ use crate::{Assist, AssistCtx, AssistId}; | |||
18 | // let _ = 2 + 90; | 17 | // let _ = 2 + 90; |
19 | // } | 18 | // } |
20 | // ``` | 19 | // ``` |
21 | pub(crate) fn flip_binexpr(ctx: AssistCtx<impl HirDatabase>) -> Option<Assist> { | 20 | pub(crate) fn flip_binexpr(ctx: AssistCtx) -> Option<Assist> { |
22 | let expr = ctx.find_node_at_offset::<BinExpr>()?; | 21 | let expr = ctx.find_node_at_offset::<BinExpr>()?; |
23 | let lhs = expr.lhs()?.syntax().clone(); | 22 | let lhs = expr.lhs()?.syntax().clone(); |
24 | let rhs = expr.rhs()?.syntax().clone(); | 23 | let rhs = expr.rhs()?.syntax().clone(); |