-
Notifications
You must be signed in to change notification settings - Fork 13.1k
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
Explanation of E0207 is not what actually happens #62144
Comments
@yshui I would like to address this. What should be error message for E0207? |
@ayushmishra2005 Maybe just don't mention lifetime parameter? |
@yshui I think this has been fixed already. Can you please try again? |
@ayushmishra2005 I don't think it has been: https://github.com/rust-lang/rust/blob/master/src/librustc_error_codes/error_codes/E0207.md still mentions lifetime parameter. |
@yshui Sorry My bad. I missed checking this file. Let me fix and raise PR. |
@ayushmishra2005 Thanks 👍 |
Unconstrained lifetime parameters are actually allowed:
https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=e4deca509f64a6d600ae49904e966124
Unlike what's described here:
rust/src/librustc_typeck/error_codes.rs
Lines 1941 to 1950 in d3e2cec
For comparison, unconstrained type parameters do generate error:
https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=a4d2a865a8a311e0eb46f8ed8583c671
The text was updated successfully, but these errors were encountered: