Rustup to rust-lang/rust#60966
This commit is contained in:
parent
2bff3d87d5
commit
3c11406c1f
@ -15,7 +15,7 @@ use rustc::{declare_lint_pass, declare_tool_lint};
|
||||
use rustc_errors::Applicability;
|
||||
use syntax::ast;
|
||||
use syntax::source_map::Span;
|
||||
use syntax::symbol::LocalInternedString;
|
||||
use syntax::symbol::{sym, LocalInternedString};
|
||||
|
||||
use crate::utils::sugg;
|
||||
use crate::utils::usage::mutated_variables;
|
||||
@ -2682,7 +2682,7 @@ fn get_error_type<'a>(cx: &LateContext<'_, '_>, ty: Ty<'a>) -> Option<Ty<'a>> {
|
||||
|
||||
/// This checks whether a given type is known to implement Debug.
|
||||
fn has_debug_impl<'a, 'b>(ty: Ty<'a>, cx: &LateContext<'b, 'a>) -> bool {
|
||||
match cx.tcx.lang_items().debug_trait() {
|
||||
match cx.tcx.get_diagnostic_item(sym::debug_trait) {
|
||||
Some(debug) => implements_trait(cx, ty, debug, &[]),
|
||||
None => false,
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user