about summary refs log tree commit diff
path: root/src/librustc_error_codes/error_codes
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2020-03-05 21:39:00 +0000
committerbors <bors@rust-lang.org>2020-03-05 21:39:00 +0000
commitb818ccc74c993d41286731f67ce1e2bc2a3f1918 (patch)
tree6743244ae1971d5aeab96ba3f6e27eb395787de4 /src/librustc_error_codes/error_codes
parent96bb8b31c81dc2394317f2f083c3acf8087efea1 (diff)
parent80c843431d54a4afb7ec92ceaa37cf4faa0a0653 (diff)
downloadrust-b818ccc74c993d41286731f67ce1e2bc2a3f1918.tar.gz
rust-b818ccc74c993d41286731f67ce1e2bc2a3f1918.zip
Auto merge of #69746 - Dylan-DPC:rollup-wr6dvdk, r=Dylan-DPC
Rollup of 8 pull requests

Successful merges:

 - #69697 (Add explanation for E0380)
 - #69698 (Use associated constants of integer types)
 - #69711 (Update macros.rs: fix documentation typo.)
 - #69713 (more clippy cleanups)
 - #69728 (Make link to `std::str` active)
 - #69732 (Clean E0382 and E0384 explanations)
 - #69736 (even more clippy cleanups)
 - #69742 (Fixed a typo)

Failed merges:

r? @ghost
Diffstat (limited to 'src/librustc_error_codes/error_codes')
-rw-r--r--src/librustc_error_codes/error_codes/E0380.md14
-rw-r--r--src/librustc_error_codes/error_codes/E0382.md3
-rw-r--r--src/librustc_error_codes/error_codes/E0384.md2
3 files changed, 14 insertions, 5 deletions
diff --git a/src/librustc_error_codes/error_codes/E0380.md b/src/librustc_error_codes/error_codes/E0380.md
index fe5de569339..638f0c8ecc6 100644
--- a/src/librustc_error_codes/error_codes/E0380.md
+++ b/src/librustc_error_codes/error_codes/E0380.md
@@ -1,4 +1,14 @@
-Auto traits cannot have methods or associated items.
-For more information see the [opt-in builtin traits RFC][RFC 19].
+An auto trait was declared with a method or an associated item.
+
+Erroneous code example:
+
+```compile_fail,E0380
+unsafe auto trait Trait {
+    type Output; // error!
+}
+```
+
+Auto traits cannot have methods or associated items. For more information see
+the [opt-in builtin traits RFC][RFC 19].
 
 [RFC 19]: https://github.com/rust-lang/rfcs/blob/master/text/0019-opt-in-builtin-traits.md
diff --git a/src/librustc_error_codes/error_codes/E0382.md b/src/librustc_error_codes/error_codes/E0382.md
index f2356583cce..d1408a06296 100644
--- a/src/librustc_error_codes/error_codes/E0382.md
+++ b/src/librustc_error_codes/error_codes/E0382.md
@@ -1,5 +1,4 @@
-This error occurs when an attempt is made to use a variable after its contents
-have been moved elsewhere.
+A variable was used after its contents have been moved elsewhere.
 
 Erroneous code example:
 
diff --git a/src/librustc_error_codes/error_codes/E0384.md b/src/librustc_error_codes/error_codes/E0384.md
index 7c7ee744a8c..e21fac0797c 100644
--- a/src/librustc_error_codes/error_codes/E0384.md
+++ b/src/librustc_error_codes/error_codes/E0384.md
@@ -1,4 +1,4 @@
-This error occurs when an attempt is made to reassign an immutable variable.
+An immutable variable was reassigned.
 
 Erroneous code example: