File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
src/tools/rust-analyzer/crates/hir-ty/src Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -182,7 +182,7 @@ pub fn layout_of_ty_ns_query<'db>(
182182 } ;
183183 let dl = & * target;
184184 let cx = LayoutCx :: new ( dl) ;
185- let infer_ctxt = interner. infer_ctxt ( ) . build ( TypingMode :: non_body_analysis ( ) ) ;
185+ let infer_ctxt = interner. infer_ctxt ( ) . build ( TypingMode :: PostAnalysis ) ;
186186 let cause = ObligationCause :: dummy ( ) ;
187187 let ty = deeply_normalize ( infer_ctxt. at ( & cause, ParamEnv :: empty ( ) ) , ty) . unwrap_or ( ty) ;
188188 let result = match ty. kind ( ) {
@@ -368,7 +368,11 @@ pub fn layout_of_ty_ns_query<'db>(
368368 }
369369
370370 TyKind :: Error ( _) => return Err ( LayoutError :: HasErrorType ) ,
371- TyKind :: Placeholder ( _) | TyKind :: Bound ( ..) | TyKind :: Infer ( ..) | TyKind :: Param ( ..) | TyKind :: Alias ( ..) => {
371+ TyKind :: Placeholder ( _)
372+ | TyKind :: Bound ( ..)
373+ | TyKind :: Infer ( ..)
374+ | TyKind :: Param ( ..)
375+ | TyKind :: Alias ( ..) => {
372376 return Err ( LayoutError :: HasPlaceholder ) ;
373377 }
374378 } ;
You can’t perform that action at this time.
0 commit comments