]> git.lizzy.rs Git - rust.git/blobdiff - clippy_lints/src/future_not_send.rs
squash OpaqueTy and ProjectionTy into AliasTy
[rust.git] / clippy_lints / src / future_not_send.rs
index 8a7a65c860016d0ac1b51e8716462d5327b4d68a..3ff774867b1efd264c0e9be0135e51604f251a96 100644 (file)
@@ -4,7 +4,7 @@
 use rustc_hir::{Body, FnDecl, HirId};
 use rustc_infer::infer::TyCtxtInferExt;
 use rustc_lint::{LateContext, LateLintPass};
-use rustc_middle::ty::{Clause, EarlyBinder, Opaque, OpaqueTy, PredicateKind};
+use rustc_middle::ty::{AliasTy, Clause, EarlyBinder, Opaque, PredicateKind};
 use rustc_session::{declare_lint_pass, declare_tool_lint};
 use rustc_span::{sym, Span};
 use rustc_trait_selection::traits::error_reporting::suggestions::TypeErrCtxtExt;
@@ -62,7 +62,7 @@ fn check_fn(
             return;
         }
         let ret_ty = return_ty(cx, hir_id);
-        if let Opaque(OpaqueTy { def_id, substs }) = *ret_ty.kind() {
+        if let Opaque(AliasTy { def_id, substs }) = *ret_ty.kind() {
             let preds = cx.tcx.explicit_item_bounds(def_id);
             let mut is_future = false;
             for &(p, _span) in preds {