@@ -93,9 +93,9 @@ declare_clippy_lint! {
9393 /// ```rust
9494 /// expr.span.ctxt().outer_expn_info()
9595 /// ```
96- pub OUTER_EXPN_INFO ,
96+ pub OUTER_EXPN_EXPN_INFO ,
9797 internal,
98- "using `cx.outer ().expn_info()` instead of `cx.outer_expn_info()`"
98+ "using `cx.outer_expn ().expn_info()` instead of `cx.outer_expn_info()`"
9999}
100100
101101declare_lint_pass ! ( ClippyLintsInternal => [ CLIPPY_LINTS_INTERNAL ] ) ;
@@ -280,15 +280,15 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for CompilerLintFunctions {
280280
281281pub struct OuterExpnInfoPass ;
282282
283- impl_lint_pass ! ( OuterExpnInfoPass => [ OUTER_EXPN_INFO ] ) ;
283+ impl_lint_pass ! ( OuterExpnInfoPass => [ OUTER_EXPN_EXPN_INFO ] ) ;
284284
285285impl < ' a , ' tcx > LateLintPass < ' a , ' tcx > for OuterExpnInfoPass {
286286 fn check_expr ( & mut self , cx : & LateContext < ' a , ' tcx > , expr : & ' tcx hir:: Expr ) {
287287 let ( method_names, arg_lists) = method_calls ( expr, 2 ) ;
288288 let method_names: Vec < LocalInternedString > = method_names. iter ( ) . map ( |s| s. as_str ( ) ) . collect ( ) ;
289289 let method_names: Vec < & str > = method_names. iter ( ) . map ( std:: convert:: AsRef :: as_ref) . collect ( ) ;
290290 if_chain ! {
291- if let [ "expn_info" , "outer " ] = method_names. as_slice( ) ;
291+ if let [ "expn_info" , "outer_expn " ] = method_names. as_slice( ) ;
292292 let args = arg_lists[ 1 ] ;
293293 if args. len( ) == 1 ;
294294 let self_arg = & args[ 0 ] ;
@@ -297,9 +297,9 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for OuterExpnInfoPass {
297297 then {
298298 span_lint_and_sugg(
299299 cx,
300- OUTER_EXPN_INFO ,
300+ OUTER_EXPN_EXPN_INFO ,
301301 expr. span. trim_start( self_arg. span) . unwrap_or( expr. span) ,
302- "usage of `outer ().expn_info()`" ,
302+ "usage of `outer_expn ().expn_info()`" ,
303303 "try" ,
304304 ".outer_expn_info()" . to_string( ) ,
305305 Applicability :: MachineApplicable ,
0 commit comments