about summary refs log tree commit diff
path: root/src/librustc_errors
diff options
context:
space:
mode:
authorJeremy Fitzhardinge <jsgf@fb.com>2019-05-21 12:38:46 -0700
committerJeremy Fitzhardinge <jsgf@fb.com>2019-05-21 13:51:36 -0700
commit6c3862594210cc0a5e60fbad32d3aab7a4fb512c (patch)
tree8843a8f4a17c54514ab2937b87e3ea0b9ad93806 /src/librustc_errors
parent09189591c4c4f6784ffd4bbe99eaefbfe1d5e4a4 (diff)
downloadrust-6c3862594210cc0a5e60fbad32d3aab7a4fb512c.tar.gz
rust-6c3862594210cc0a5e60fbad32d3aab7a4fb512c.zip
Make -Zemit-artifact-notifications also emit the artifact type
This is easier for tooling to handle than trying to reverse-engineer it from the filename extension.
Diffstat (limited to 'src/librustc_errors')
-rw-r--r--src/librustc_errors/emitter.rs2
-rw-r--r--src/librustc_errors/lib.rs4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/librustc_errors/emitter.rs b/src/librustc_errors/emitter.rs
index 59cbd65f05c..b56162deaf1 100644
--- a/src/librustc_errors/emitter.rs
+++ b/src/librustc_errors/emitter.rs
@@ -56,7 +56,7 @@ pub trait Emitter {
     /// Emit a notification that an artifact has been output.
     /// This is currently only supported for the JSON format,
     /// other formats can, and will, simply ignore it.
-    fn emit_artifact_notification(&mut self, _path: &Path) {}
+    fn emit_artifact_notification(&mut self, _path: &Path, _artifact_type: &str) {}
 
     /// Checks if should show explanations about "rustc --explain"
     fn should_show_explain(&self) -> bool {
diff --git a/src/librustc_errors/lib.rs b/src/librustc_errors/lib.rs
index 3aa87fad071..2dcf7be2aa8 100644
--- a/src/librustc_errors/lib.rs
+++ b/src/librustc_errors/lib.rs
@@ -769,8 +769,8 @@ impl Handler {
         }
     }
 
-    pub fn emit_artifact_notification(&self, path: &Path) {
-        self.emitter.borrow_mut().emit_artifact_notification(path);
+    pub fn emit_artifact_notification(&self, path: &Path, artifact_type: &str) {
+        self.emitter.borrow_mut().emit_artifact_notification(path, artifact_type);
     }
 }