Skip to content
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

Future compat warning #254

Closed
est31 opened this issue Jul 17, 2019 · 2 comments · Fixed by #260
Closed

Future compat warning #254

est31 opened this issue Jul 17, 2019 · 2 comments · Fixed by #260

Comments

@est31
Copy link
Contributor

est31 commented Jul 17, 2019

Currently, there is a future compat warning firing when building the codebase:

warning: cannot specify lifetime arguments explicitly if late bound lifetime parameters are present
   --> src/rules_and_declarations.rs:537:30
    |
537 |         parse_until_before::<'i, 't, _, _, _>(input, Delimiter::CurlyBracketBlock, |input| {
    |                              ^^
    | 
   ::: src/parser.rs:959:13
    |
959 |     parser: &mut Parser<'i, 't>,
    |             - the late bound lifetime parameter is introduced here
    |
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
    = note: for more information, see issue #42868 <https://github.com/rust-lang/rust/issues/42868>
@SimonSapin
Copy link
Member

Yes, I am unhappy about this warning.

The diagnostic is not clear at all, and even after much discussion in rust-lang/rust#42868 and on IRC I’m not sure what it means. None of the possible fixes suggested by various people are accepted by the compiler for this code.

So we’re stuck with an obscure warning we can’t silence and that no-one knows how to fix.

@lqd
Copy link
Contributor

lqd commented Oct 16, 2019

For documentation purposes, here's a summary of the situation:

When the rustc bug is fixed, these callback variables can be removed by inlining them as arguments to these 4 function calls (and the type annotation on the closure parameter will also become unnecessary).

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 a pull request may close this issue.

3 participants