about summary refs log tree commit diff
path: root/src/librustc_error_codes/error_codes
diff options
context:
space:
mode:
authorAyush Kumar Mishra <ayush.k.mishra@xcelenergy.com>2020-03-14 08:41:05 +0530
committerAyush Kumar Mishra <ayush.k.mishra@xcelenergy.com>2020-03-14 08:41:05 +0530
commit1c88052fa0dd0aae4f01f60ea9c42699952698ba (patch)
tree90de4aad2596770e4e2ed2e9548e033fd03e7821 /src/librustc_error_codes/error_codes
parent3dbade652ed8ebac70f903e01f51cd92c4e4302c (diff)
downloadrust-1c88052fa0dd0aae4f01f60ea9c42699952698ba.tar.gz
rust-1c88052fa0dd0aae4f01f60ea9c42699952698ba.zip
Add long error explanation for E0693 #61137
Diffstat (limited to 'src/librustc_error_codes/error_codes')
-rw-r--r--src/librustc_error_codes/error_codes/E0693.md19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/librustc_error_codes/error_codes/E0693.md b/src/librustc_error_codes/error_codes/E0693.md
new file mode 100644
index 00000000000..43e9d17979e
--- /dev/null
+++ b/src/librustc_error_codes/error_codes/E0693.md
@@ -0,0 +1,19 @@
+`align` representation hint was incorrectly declared.
+
+Erroneous code examples:
+
+```compile_fail,E0693
+#[repr(align=8)] // error!
+struct Align8(i8);
+
+#[repr(align="8")] // error!
+struct Align8(i8);
+```
+
+This is a syntax error at the level of attribute declarations. The proper
+syntax for `align` representation hint is the following:
+
+```
+#[repr(align(8))] // ok!
+struct Align8(i8);
+```