-
Notifications
You must be signed in to change notification settings - Fork 13.3k
foreign function invalid error message #31481
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
Comments
What behaviour do you expect? Depending on exactly what you're hoping happens, I don't think this is a bug, since Also, writing extern "C" fn foo(x: u8); // error: expected one of `->`, `where`, or `{`, found `;` I suppose the error message could possibly be clearer and/or have a |
Since the original message came from a lack of knowledge, I changed the title to better reflect the "real" issue here. |
Continue parsing function after finding `...` arg When encountering a variadic argument in a function definition that doesn't accept it, if immediately after there's a closing paren, continue parsing as normal. Otherwise keep current behavior of emitting error and stopping. Fix rust-lang#31481.
Continue parsing function after finding `...` arg When encountering a variadic argument in a function definition that doesn't accept it, if immediately after there's a closing paren, continue parsing as normal. Otherwise keep current behavior of emitting error and stopping. Fix rust-lang#31481.
This code works:
While this one doesn't:
I don't think this is the expected behavior.
The text was updated successfully, but these errors were encountered: