-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
rustdoc panic when trying to build docs #50159
Comments
pietroalbini
added
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-dev-tools-rustdoc
C-bug
Category: This is a bug.
labels
Apr 24, 2018
Strange... Will take a look as soon as possible. |
So the call is performed here. I'll need help from @nikomatsakis (or anyone in the @rust-lang/compiler team who knows about the |
Reduced further: pub trait Signal {
type Item;
}
pub trait Signal2 {
type Item2;
}
// Impl Signal2 for all impls of Signal
impl<B, C> Signal2 for B where B: Signal<Item = C> {
type Item2 = C;
}
pub struct Switch<B: Signal> {
pub inner: <B as Signal2>::Item2,
} |
I'd like to work on this. |
Aaron1011
added a commit
to Aaron1011/rust
that referenced
this issue
Oct 24, 2018
Fixes rust-lang#50159 This commit makes several improvements to AutoTraitFinder: * Call infcx.resolve_type_vars_if_possible before processing new predicates. This ensures that we eliminate inference variables wherever possible. * Process all nested obligations we get from a vtable, not just ones with depth=1. * The 'depth=1' check was a hack to work around issues processing certain predicates. The other changes in this commit allow us to properly process all predicates that we encounter, so the check is no longer necessary, * Ensure that we only display predicates *without* inference variables to the user, and only attempt to unify predicates that *have* an inference variable as their type. Additionally, the internal helper method is_of_param now operates directly on a type, rather than taking a Substs. This allows us to use the 'self_ty' method, rather than directly dealing with Substs.
bors
added a commit
that referenced
this issue
Nov 27, 2018
Ensure that Rustdoc discovers all necessary auto trait bounds Fixes #50159 This commit makes several improvements to AutoTraitFinder: * Call infcx.resolve_type_vars_if_possible before processing new predicates. This ensures that we eliminate inference variables wherever possible. * Process all nested obligations we get from a vtable, not just ones with depth=1. * The 'depth=1' check was a hack to work around issues processing certain predicates. The other changes in this commit allow us to properly process all predicates that we encounter, so the check is no longer necessary, * Ensure that we only display predicates *without* inference variables to the user, and only attempt to unify predicates that *have* an inference variable as their type. Additionally, the internal helper method is_of_param now operates directly on a type, rather than taking a Substs. This allows us to use the 'self_ty' method, rather than directly dealing with Substs.
Aaron1011
added a commit
to Aaron1011/rust
that referenced
this issue
Nov 29, 2018
Fixes rust-lang#50159 This commit makes several improvements to AutoTraitFinder: * Call infcx.resolve_type_vars_if_possible before processing new predicates. This ensures that we eliminate inference variables wherever possible. * Process all nested obligations we get from a vtable, not just ones with depth=1. * The 'depth=1' check was a hack to work around issues processing certain predicates. The other changes in this commit allow us to properly process all predicates that we encounter, so the check is no longer necessary, * Ensure that we only display predicates *without* inference variables to the user, and only attempt to unify predicates that *have* an inference variable as their type. Additionally, the internal helper method is_of_param now operates directly on a type, rather than taking a Substs. This allows us to use the 'self_ty' method, rather than directly dealing with Substs.
bors
added a commit
that referenced
this issue
Dec 6, 2018
…matsakis Ensure that Rustdoc discovers all necessary auto trait bounds Fixes #50159 This commit makes several improvements to AutoTraitFinder: * Call infcx.resolve_type_vars_if_possible before processing new predicates. This ensures that we eliminate inference variables wherever possible. * Process all nested obligations we get from a vtable, not just ones with depth=1. * The 'depth=1' check was a hack to work around issues processing certain predicates. The other changes in this commit allow us to properly process all predicates that we encounter, so the check is no longer necessary, * Ensure that we only display predicates *without* inference variables to the user, and only attempt to unify predicates that *have* an inference variable as their type. Additionally, the internal helper method is_of_param now operates directly on a type, rather than taking a Substs. This allows us to use the 'self_ty' method, rather than directly dealing with Substs.
@GuillaumeGomez @dtolnay @Aaron1011 Thank you so much! I verified that with the latest Rust Nightly I no longer get any errors. |
pietroalbini
pushed a commit
to pietroalbini/rust
that referenced
this issue
Jan 3, 2019
Fixes rust-lang#50159 This commit makes several improvements to AutoTraitFinder: * Call infcx.resolve_type_vars_if_possible before processing new predicates. This ensures that we eliminate inference variables wherever possible. * Process all nested obligations we get from a vtable, not just ones with depth=1. * The 'depth=1' check was a hack to work around issues processing certain predicates. The other changes in this commit allow us to properly process all predicates that we encounter, so the check is no longer necessary, * Ensure that we only display predicates *without* inference variables to the user, and only attempt to unify predicates that *have* an inference variable as their type. Additionally, the internal helper method is_of_param now operates directly on a type, rather than taking a Substs. This allows us to use the 'self_ty' method, rather than directly dealing with Substs.
Aaron1011
added a commit
to Aaron1011/rust
that referenced
this issue
Jan 4, 2019
Fixes rust-lang#50159 This commit makes several improvements to AutoTraitFinder: * Call infcx.resolve_type_vars_if_possible before processing new predicates. This ensures that we eliminate inference variables wherever possible. * Process all nested obligations we get from a vtable, not just ones with depth=1. * The 'depth=1' check was a hack to work around issues processing certain predicates. The other changes in this commit allow us to properly process all predicates that we encounter, so the check is no longer necessary, * Ensure that we only display predicates *without* inference variables to the user, and only attempt to unify predicates that *have* an inference variable as their type. Additionally, the internal helper method is_of_param now operates directly on a type, rather than taking a Substs. This allows us to use the 'self_ty' method, rather than directly dealing with Substs.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When I tried to build docs for my signals library, I got a panic.
Here is the reduced test case:
With the above code, when I run
cargo doc --release
I get this panic:Meta
rustc 1.27.0-nightly (ac3c228 2018-04-18)
binary: rustc
commit-hash: ac3c228
commit-date: 2018-04-18
host: x86_64-pc-windows-msvc
release: 1.27.0-nightly
LLVM version: 6.0
The text was updated successfully, but these errors were encountered: