about summary refs log tree commit diff
diff options
context:
space:
mode:
authorTakayuki Maeda <takoyaki0316@gmail.com>2022-10-05 22:46:44 +0900
committerTakayuki Maeda <takoyaki0316@gmail.com>2022-10-05 22:46:44 +0900
commit760279f3cc6434fcb1708a741bddfa4bd9d10efb (patch)
treeb98851c8bd4e4712c85326c8b1d97cb96799a530
parent65445a571c11f07f4ca1ed0f63bad247ae295bd0 (diff)
downloadrust-760279f3cc6434fcb1708a741bddfa4bd9d10efb.tar.gz
rust-760279f3cc6434fcb1708a741bddfa4bd9d10efb.zip
use smaller span
-rw-r--r--compiler/rustc_hir_analysis/src/check/expr.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_hir_analysis/src/check/expr.rs b/compiler/rustc_hir_analysis/src/check/expr.rs
index 48a4f40780b..d7009c56444 100644
--- a/compiler/rustc_hir_analysis/src/check/expr.rs
+++ b/compiler/rustc_hir_analysis/src/check/expr.rs
@@ -1066,9 +1066,9 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
             }
             if eq {
                 err.span_suggestion_verbose(
-                    span,
+                    span.shrink_to_hi(),
                     "you might have meant to compare for equality",
-                    "==",
+                    '=',
                     applicability,
                 );
             }