-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Nightly regression around HRTBs, likely connected to wf changes #28934
Comments
cc @arielb1 |
The above is a reduction of servo/rust-cssparser@29f757d |
A quick scan of the intervening commits suggests 603a75c may be related. |
Treat url(<string>) as a normal functions, per spec change. Only unquoted URLs are special tokens now. Use `Parser::expect_url`. This is a [breaking-change]. The version number was incremented accordingly. This change will help with servo/servo#7767 This triggers rust-lang/rust#28934 and fails to build in the current Rust nightly, but works fine in the Rust version that Servo currently use. Hopefully that rustc bug will be fixed before we need to upgrade Rust in Servo. r? @mbrubeck <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/rust-cssparser/90) <!-- Reviewable:end -->
The eta-reduced version fails on all versions of rustc: struct Parser<'i: 't, 't>(&'i u8, &'t u8);
impl<'i, 't> Parser<'i, 't> {
fn parse_nested_block<F, T>(&mut self, parse: F) -> Result<T, ()>
where for<'tt> F: FnOnce(&mut Parser<'i, 'tt>) -> T { panic!() }
fn expect_exhausted(&mut self) -> Result<(), ()> { Ok(()) }
}
fn main() {
let x = 0u8;
Parser(&x, &x).parse_nested_block(Parser::expect_exhausted).unwrap();
}
The wf fixes just bought it in line. |
The UFCS version fails on 1.4+, but succeeds if you annotate the parameter type - this looks like a closure inference issue. |
This was not fixed by #29006 |
triage: P-high |
/me investigating THIS now |
This seems to boil down to a bug in the givens list for region inference. It is fixed by #29188 (at least, it is with the latest commit). |
Treat url(<string>) as a normal functions, per spec change. Only unquoted URLs are special tokens now. Use `Parser::expect_url`. This is a [breaking-change]. The version number was incremented accordingly. This change will help with servo/servo#7767 This triggers rust-lang/rust#28934 and fails to build in the current Rust nightly, but works fine in the Rust version that Servo currently use. Hopefully that rustc bug will be fixed before we need to upgrade Rust in Servo. r? @mbrubeck <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/rust-cssparser/90) <!-- Reviewable:end -->
expansion already by growing the RHS to be bigger than LHS (all the way to `'static` if necessary). This is needed because contraction doesn't handle givens. Fixes rust-lang#28934.
Treat url(<string>) as a normal functions, per spec change. Only unquoted URLs are special tokens now. Use `Parser::expect_url`. This is a [breaking-change]. The version number was incremented accordingly. This change will help with servo/servo#7767 This triggers rust-lang/rust#28934 and fails to build in the current Rust nightly, but works fine in the Rust version that Servo currently use. Hopefully that rustc bug will be fixed before we need to upgrade Rust in Servo. r? @mbrubeck <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/rust-cssparser/90) <!-- Reviewable:end -->
The following code:
compiles on 1.3 stable and 1.4 beta, but not on nightly. This seems likely related to wf changes.
The text was updated successfully, but these errors were encountered: