summary refs log tree commit diff
path: root/src/libcore
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2020-01-23 11:51:56 -0800
committerEsteban Küber <esteban@kuber.com.ar>2020-01-23 11:51:56 -0800
commit6eaf59dfc8be4ee5647f9c090c5a7668682f30c0 (patch)
treed3763ff2dd82a1d96b9319748de88101229f8668 /src/libcore
parentc775927d7fee06743631d138eac91a862c8f6faf (diff)
downloadrust-6eaf59dfc8be4ee5647f9c090c5a7668682f30c0.tar.gz
rust-6eaf59dfc8be4ee5647f9c090c5a7668682f30c0.zip
use `diagnostic_item` and modify wording
Diffstat (limited to 'src/libcore')
-rw-r--r--src/libcore/option.rs1
-rw-r--r--src/libcore/result.rs1
2 files changed, 2 insertions, 0 deletions
diff --git a/src/libcore/option.rs b/src/libcore/option.rs
index a471b174534..cb4247d9874 100644
--- a/src/libcore/option.rs
+++ b/src/libcore/option.rs
@@ -151,6 +151,7 @@ use crate::{
 
 /// The `Option` type. See [the module level documentation](index.html) for more.
 #[derive(Copy, PartialEq, PartialOrd, Eq, Ord, Debug, Hash)]
+#[rustc_diagnostic_item = "option_type"]
 #[stable(feature = "rust1", since = "1.0.0")]
 pub enum Option<T> {
     /// No value
diff --git a/src/libcore/result.rs b/src/libcore/result.rs
index c657ce33f60..bc70dbd62eb 100644
--- a/src/libcore/result.rs
+++ b/src/libcore/result.rs
@@ -242,6 +242,7 @@ use crate::ops::{self, Deref, DerefMut};
 /// [`Err`]: enum.Result.html#variant.Err
 #[derive(Copy, PartialEq, PartialOrd, Eq, Ord, Debug, Hash)]
 #[must_use = "this `Result` may be an `Err` variant, which should be handled"]
+#[rustc_diagnostic_item = "result_type"]
 #[stable(feature = "rust1", since = "1.0.0")]
 pub enum Result<T, E> {
     /// Contains the success value