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-16 02:52:47 +0000
committerbors <bors@rust-lang.org>2020-03-16 02:52:47 +0000
commit97eda01bb79de1e0a52994f52cfb5a527687f505 (patch)
treee672e08f84632cbef14a7aec025e360f907b4f2c /src/librustc_error_codes/error_codes
parent45ebd5808afd3df7ba842797c0fcd4447ddf30fb (diff)
parent6b50a4cebb55db54104a071c74f2fc74de17b6af (diff)
downloadrust-97eda01bb79de1e0a52994f52cfb5a527687f505.tar.gz
rust-97eda01bb79de1e0a52994f52cfb5a527687f505.zip
Auto merge of #70034 - Dylan-DPC:rollup-5yg771j, r=Dylan-DPC
Rollup of 8 pull requests

Successful merges:

 - #69686 (Use `pprust` to print attributes in rustdoc)
 - #69858 (std: on Windows, use GetSystemTimePreciseAsFileTime if it is available)
 - #69917 (Cleanup E0412 and E0422)
 - #69964 (Add Node.js to PR CI image)
 - #69992 (Block version-specific docs from search engines)
 - #69995 (Add more context to the literal overflow message)
 - #69998 (Add long error explanation for E0634)
 - #70014 (Small fixes in rustdoc book)

Failed merges:

r? @ghost
Diffstat (limited to 'src/librustc_error_codes/error_codes')
-rw-r--r--src/librustc_error_codes/error_codes/E0412.md2
-rw-r--r--src/librustc_error_codes/error_codes/E0422.md3
-rw-r--r--src/librustc_error_codes/error_codes/E0634.md20
3 files changed, 23 insertions, 2 deletions
diff --git a/src/librustc_error_codes/error_codes/E0412.md b/src/librustc_error_codes/error_codes/E0412.md
index 60a09610d86..d9ebc852bba 100644
--- a/src/librustc_error_codes/error_codes/E0412.md
+++ b/src/librustc_error_codes/error_codes/E0412.md
@@ -1,4 +1,4 @@
-The type name used is not in scope.
+A used type name is not in scope.
 
 Erroneous code examples:
 
diff --git a/src/librustc_error_codes/error_codes/E0422.md b/src/librustc_error_codes/error_codes/E0422.md
index a91ea6a9e22..828a52e7341 100644
--- a/src/librustc_error_codes/error_codes/E0422.md
+++ b/src/librustc_error_codes/error_codes/E0422.md
@@ -1,4 +1,5 @@
-You are trying to use an identifier that is either undefined or not a struct.
+An identifier that is neither defined nor a struct was used.
+
 Erroneous code example:
 
 ```compile_fail,E0422
diff --git a/src/librustc_error_codes/error_codes/E0634.md b/src/librustc_error_codes/error_codes/E0634.md
new file mode 100644
index 00000000000..0c4ed2596e2
--- /dev/null
+++ b/src/librustc_error_codes/error_codes/E0634.md
@@ -0,0 +1,20 @@
+A type has conflicting `packed` representation hints.
+
+Erroneous code examples:
+
+```compile_fail,E0634
+#[repr(packed, packed(2))] // error!
+struct Company(i32);
+
+#[repr(packed(2))] // error!
+#[repr(packed)]
+struct Company(i32);
+```
+
+You cannot use conflicting `packed` hints on a same type. If you want to pack a
+type to a given size, you should provide a size to packed:
+
+```
+#[repr(packed)] // ok!
+struct Company(i32);
+```