Skip to content

Unify variadic errors #26503

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jun 23, 2015
Merged

Unify variadic errors #26503

merged 5 commits into from
Jun 23, 2015

Conversation

GuillaumeGomez
Copy link
Member

@@ -380,6 +380,23 @@ fn main() {
```
"##,

E0045: r##"
Variadic parameters are only allowed in extern "C" code. Example of
erroneous codes:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Examples of erroneous code"

@GuillaumeGomez
Copy link
Member Author

@Manishearth: Updated, thanks for your help ! Do you see anything else ?

fn foo(x: u8, ...) {}
```

To fix such code, put them in extern "C" block:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"put them in an extern ..."

Also, you misinterpreted my suggestion... there are two ways to fix this error, one is to do:

extern "C" { ... } and the other is to use extern "C" fn.

@GuillaumeGomez
Copy link
Member Author

Updated.

@@ -1535,7 +1556,6 @@ register_diagnostics! {
E0219, // associated type defined in higher-ranked supertrait
E0220, // associated type not found for type parameter
E0221, // ambiguous associated type in bounds
E0222, // variadic function must have C calling convention
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leave this line in, commented out with an indicator that it's been merged with E0045

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes sir !

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still needs some indicator comment saying "merged into E0045" 😄

@GuillaumeGomez
Copy link
Member Author

Done !

@GuillaumeGomez
Copy link
Member Author

Oh I almost forgot : #24407.

@GuillaumeGomez
Copy link
Member Author

@Manishearth: I added the "merged into E0045"

@Manishearth
Copy link
Member

@bors-servo r+ rollup

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

📌 Commit f1a3651 has been approved by Manishearth

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

⌛ Testing commit f1a3651 with merge d0df233...

@Manishearth
Copy link
Member

@bors r- force

error: duplicate error code E0045

We should comment it out in a way that tidy will not complain on. Perhaps // Error code E0045 (variadic ...) was merged into E0222

@Manishearth
Copy link
Member

@bors force

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

⛄ The build was interrupted to prioritize another pull request.

@GuillaumeGomez
Copy link
Member Author

Updated !

@Manishearth
Copy link
Member

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

📌 Commit 3ff1222 has been approved by Manishearth

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

⌛ Testing commit 3ff1222 with merge ec40bc1...

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

💔 Test failed - auto-win-gnu-32-nopt-t

@Manishearth
Copy link
Member

@bors retry

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

⌛ Testing commit 3ff1222 with merge d260b1b...

@alexcrichton
Copy link
Member

@bors: retry

On Mon, Jun 22, 2015 at 11:23 PM, bors notifications@github.com wrote:

[image: 💔] Test failed - auto-win-gnu-32-nopt-t
http://buildbot.rust-lang.org/builders/auto-win-gnu-32-nopt-t/builds/435


Reply to this email directly or view it on GitHub
#26503 (comment).

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

⌛ Testing commit 3ff1222 with merge 23edf36...

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

💔 Test failed - auto-mac-64-nopt-t

@Manishearth
Copy link
Member

@bors: retry

@bors
Copy link
Collaborator

bors commented Jun 23, 2015

⌛ Testing commit 3ff1222 with merge d54ab41...

@bors bors merged commit 3ff1222 into rust-lang:master Jun 23, 2015
@GuillaumeGomez GuillaumeGomez deleted the patch-4 branch June 24, 2015 09:59
@jroesch
Copy link
Member

jroesch commented Jul 8, 2015

@GuillaumeGomez it looks like this PR was the one that causes a build warning to be generated about previously used diagnostic error codes, could you possible fix this? I know its nit-picky but false warnings drive me nuts.

@GuillaumeGomez
Copy link
Member Author

Sure, I'll do it this evening.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants