about summary refs log tree commit diff
path: root/compiler
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2023-11-30 14:40:26 +1100
committerNicholas Nethercote <n.nethercote@gmail.com>2023-12-02 08:58:25 +1100
commitc3628bb9705cf55022733ec82f070dc50d56bfad (patch)
treea5ea61f250901a2b12f615b15dfa72f193444efe /compiler
parent7138845f61ee8eb212158fd4b66276e34e733db1 (diff)
downloadrust-c3628bb9705cf55022733ec82f070dc50d56bfad.tar.gz
rust-c3628bb9705cf55022733ec82f070dc50d56bfad.zip
Rename `HandlerInner::failure` as `HandlerInner::failure_note`.
To match the `FailureNote` variant of `Level`.
Diffstat (limited to 'compiler')
-rw-r--r--compiler/rustc_errors/src/lib.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_errors/src/lib.rs b/compiler/rustc_errors/src/lib.rs
index 9f2e5d81797..dc3b189c4c2 100644
--- a/compiler/rustc_errors/src/lib.rs
+++ b/compiler/rustc_errors/src/lib.rs
@@ -1502,18 +1502,18 @@ impl HandlerInner {
                 error_codes.sort();
                 if error_codes.len() > 1 {
                     let limit = if error_codes.len() > 9 { 9 } else { error_codes.len() };
-                    self.failure(format!(
+                    self.failure_note(format!(
                         "Some errors have detailed explanations: {}{}",
                         error_codes[..limit].join(", "),
                         if error_codes.len() > 9 { "..." } else { "." }
                     ));
-                    self.failure(format!(
+                    self.failure_note(format!(
                         "For more information about an error, try \
                          `rustc --explain {}`.",
                         &error_codes[0]
                     ));
                 } else {
-                    self.failure(format!(
+                    self.failure_note(format!(
                         "For more information about this error, try \
                          `rustc --explain {}`.",
                         &error_codes[0]
@@ -1633,7 +1633,7 @@ impl HandlerInner {
         self.delayed_good_path_bugs.push(DelayedDiagnostic::with_backtrace(diagnostic, backtrace));
     }
 
-    fn failure(&mut self, msg: impl Into<DiagnosticMessage>) {
+    fn failure_note(&mut self, msg: impl Into<DiagnosticMessage>) {
         self.emit_diagnostic(&mut Diagnostic::new(FailureNote, msg));
     }