77//! purely for "IDE needs".
88use std:: sync:: Arc ;
99
10+ use either:: Either ;
1011use hir_def:: {
1112 body:: {
1213 scope:: { ExprScopes , ScopeId } ,
@@ -33,8 +34,8 @@ use crate::{
3334 method_resolution:: { self , implements_trait} ,
3435 InEnvironment , TraitEnvironment , Ty ,
3536 } ,
36- Adt , AssocItem , Const , DefWithBody , Either , Enum , EnumVariant , FromSource , Function ,
37- GenericParam , Local , MacroDef , Name , Path , ScopeDef , Static , Struct , Trait , Type , TypeAlias ,
37+ Adt , AssocItem , Const , DefWithBody , Enum , EnumVariant , FromSource , Function , GenericParam ,
38+ Local , MacroDef , Name , Path , ScopeDef , Static , Struct , Trait , Type , TypeAlias ,
3839} ;
3940
4041fn try_get_resolver_for_node ( db : & impl HirDatabase , node : InFile < & SyntaxNode > ) -> Option < Resolver > {
@@ -349,7 +350,7 @@ impl SourceAnalyzer {
349350 // should switch to general reference search infra there.
350351 pub fn find_all_refs ( & self , pat : & ast:: BindPat ) -> Vec < ReferenceDescriptor > {
351352 let fn_def = pat. syntax ( ) . ancestors ( ) . find_map ( ast:: FnDef :: cast) . unwrap ( ) ;
352- let ptr = Either :: A ( AstPtr :: new ( & ast:: Pat :: from ( pat. clone ( ) ) ) ) ;
353+ let ptr = Either :: Left ( AstPtr :: new ( & ast:: Pat :: from ( pat. clone ( ) ) ) ) ;
353354 fn_def
354355 . syntax ( )
355356 . descendants ( )
0 commit comments