Compiler unable to determine two types are equal #70703
Labels
A-associated-items
Area: Associated items such as associated types and consts.
A-impl-trait
Area: impl Trait. Universally / existentially quantified anonymous types with static dispatch.
A-lazy-normalization
Area: lazy normalization (tracking issue: #60471)
C-bug
Category: This is a bug.
E-needs-test
Call for participation: An issue has been fixed and does not reproduce, but no test has been added.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
The compiler seems unable to determine that two types are equal.
I tried this code:
https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=b363f89f0e686e243f3a92dcc1cfc09a
I expected the program to compile and run without issue, because
<() as Factory>::Product>
is()
, so theconsume
call should be fine.Instead, I got this error message:
The problem exists on stable 1.42 and nightly 1.44
The text was updated successfully, but these errors were encountered: