]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_mir/borrow_check/nll/region_infer/error_reporting/region_name.rs
Rename `Ty.node` to `Ty.kind`
[rust.git] / src / librustc_mir / borrow_check / nll / region_infer / error_reporting / region_name.rs
index b39378f0cb7fbaa58948f7d815088d9eb06ca73e..c4b508e030f39ac76611088214ac28db0b0b3058 100644 (file)
@@ -425,7 +425,7 @@ fn give_name_if_we_can_match_hir_ty_from_argument(
         let mir_hir_id = infcx.tcx.hir().as_local_hir_id(mir_def_id)?;
         let fn_decl = infcx.tcx.hir().fn_decl_by_hir_id(mir_hir_id)?;
         let argument_hir_ty: &hir::Ty = &fn_decl.inputs[argument_index];
-        match argument_hir_ty.node {
+        match argument_hir_ty.kind {
             // This indicates a variable with no type annotation, like
             // `|x|`... in that case, we can't highlight the type but
             // must highlight the variable.
@@ -527,7 +527,7 @@ fn give_name_if_we_can_match_hir_ty(
             &mut vec![(argument_ty, argument_hir_ty)];
 
         while let Some((ty, hir_ty)) = search_stack.pop() {
-            match (&ty.kind, &hir_ty.node) {
+            match (&ty.kind, &hir_ty.kind) {
                 // Check if the `argument_ty` is `&'X ..` where `'X`
                 // is the region we are looking for -- if so, and we have a `&T`
                 // on the RHS, then we want to highlight the `&` like so:
@@ -772,7 +772,7 @@ fn give_name_if_anonymous_region_appears_in_output(
                 },
             ),
             hir::Node::ImplItem(hir::ImplItem {
-                node: hir::ImplItemKind::Method(method_sig, _),
+                kind: hir::ImplItemKind::Method(method_sig, _),
                 ..
             }) => (method_sig.decl.output.span(), ""),
             _ => (body.span, ""),