Skip to content

Commit 410be26

Browse files
---
yaml --- r: 227762 b: refs/heads/try c: 97e1615 h: refs/heads/master v: v3
1 parent 37ef080 commit 410be26

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: aca2057ed5fb7af3f8905b2bc01f72fa001c35c8
33
refs/heads/snap-stage3: 1af31d4974e33027a68126fa5a5a3c2c6491824f
4-
refs/heads/try: 3f9fc39ab91a4d75b9499d3b3591db875649a0b7
4+
refs/heads/try: 97e161573514f6f016a6e7e6db85e30d75258eb3
55
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
66
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
77
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try/src/librustc_typeck/diagnostics.rs

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -380,6 +380,23 @@ fn main() {
380380
```
381381
"##,
382382

383+
E0045: r##"
384+
Variadic parameters are only allowed in extern "C" code. Example of
385+
erroneous codes:
386+
387+
```
388+
extern "rust-call" { fn foo(x: u8, ...); }
389+
// or
390+
fn foo(x: u8, ...) {}
391+
```
392+
393+
To fix these codes, put them in extern "C" block:
394+
395+
```
396+
extern "C" { fn foo(x: u8, ...); }
397+
```
398+
"##,
399+
383400
E0046: r##"
384401
When trying to make some type implement a trait `Foo`, you must, at minimum,
385402
provide implementations for all of `Foo`'s required methods (meaning the
@@ -1467,7 +1484,6 @@ For more information see the [opt-in builtin traits RFC](https://github.com/rust
14671484

14681485
register_diagnostics! {
14691486
E0044, // foreign items may not have type parameters
1470-
E0045, // variadic function must have C calling convention
14711487
E0068,
14721488
E0071,
14731489
E0074,

0 commit comments

Comments
 (0)