Fix HashStable implementation on InferTy

This commit is contained in:
Michael Goulet 2021-12-13 20:36:17 -08:00
parent 8f117a77d0
commit 75729afcc0
2 changed files with 18 additions and 0 deletions

View file

@ -0,0 +1,17 @@
// check-pass
// incremental
struct Struct<T>(T);
impl<T> std::ops::Deref for Struct<T> {
type Target = dyn Fn(T);
fn deref(&self) -> &Self::Target {
unimplemented!()
}
}
fn main() {
let f = Struct(Default::default());
f(0);
f(0);
}