Closed Robbepop closed 5 years ago
cc @nikomatsakis
I think I have a similar ICE. The exact ICE point is:
'assertion failed: !impl_self_ty.has_infer_types()', librustc_mir/borrow_check/nll/type_check/mod.rs:1033:21
I have a snapshot of my project at https://files.myrrlyn.net/cosmonaut-ice-20181021.tar.xz
See the files ice/20181021.*
for information and the backtrace.
assigning to self to reduce to a smaller test case.
Marking as an RC2 blocker -- though it might be better to shoot for a backport?
I think we decided to push this to Rust 2018 release
I just tested and this still seems to reproduce with https://github.com/rust-lang/rust/pull/55229 :(
OK, I have a fix for this.
I did not yet manage to crate a narrowed test case for this particular case — it seems like a several similar root problem to #55219 though.
OK, here is a standalone test case:
#![feature(nll)]
pub trait Hasher {
type Out: Eq;
}
pub trait NodeCodec<H: Hasher> {
const HASHED_NULL_NODE: H::Out;
}
pub trait Trie<H: Hasher, C: NodeCodec<H>> {
fn root(&self) -> &H::Out;
fn is_empty(&self) -> bool { *self.root() == C::HASHED_NULL_NODE }
}
fn main() { }
When compiling
paritytech/parity-common
workspace usingcargo test --features std
.As far as the error shows it has something to do with the
patricia_trie
sub crate.Compiler output: