Skip to content

Commit 95870e2

Browse files
committed
Add long error explanation for E0703
1 parent 8e6de32 commit 95870e2

File tree

3 files changed

+21
-1
lines changed

3 files changed

+21
-1
lines changed

src/librustc_error_codes/error_codes.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,7 @@ E0698: include_str!("./error_codes/E0698.md"),
388388
E0699: include_str!("./error_codes/E0699.md"),
389389
E0700: include_str!("./error_codes/E0700.md"),
390390
E0701: include_str!("./error_codes/E0701.md"),
391+
E0703: include_str!("./error_codes/E0703.md"),
391392
E0704: include_str!("./error_codes/E0704.md"),
392393
E0705: include_str!("./error_codes/E0705.md"),
393394
E0706: include_str!("./error_codes/E0706.md"),
@@ -599,7 +600,6 @@ E0748: include_str!("./error_codes/E0748.md"),
599600
// E0694, // an unknown tool name found in scoped attributes
600601
E0696, // `continue` pointing to a labeled block
601602
// E0702, // replaced with a generic attribute input check
602-
E0703, // invalid ABI
603603
// E0707, // multiple elided lifetimes used in arguments of `async fn`
604604
E0708, // `async` non-`move` closures with parameters are not currently
605605
// supported
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
Invalid ABI(Application Binary Interface) used in the code.
2+
3+
Erroneous code example:
4+
5+
```compile_fail,E0703
6+
extern "invalid" fn foo() {} //~ ERROR
7+
8+
fn main() { }
9+
10+
```
11+
At present there the few predefined ABI's (like Rust, C, system, etc.)
12+
which we can use in our Rust code. Please verify the ABI from the
13+
given ABI. For example you can replace the given ABI from 'Rust'.
14+
15+
```
16+
extern "Rust" fn foo() {} //~ OK!
17+
18+
fn main() { }
19+
```

src/test/ui/codemap_tests/unicode.stderr

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ LL | extern "路濫狼á́́" fn foo() {}
88

99
error: aborting due to previous error
1010

11+
For more information about this error, try `rustc --explain E0703`.

0 commit comments

Comments
 (0)