-
Notifications
You must be signed in to change notification settings - Fork 13.4k
overflow evaluating the requirement
with impl
s those seem to be right
#74789
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
Comments
I've created more minimal example: #![recursion_limit="5"] // without it the error is the same, but much bigger
struct Nil;
struct Cons<H, T>(H, T);
pub trait Map<F> {}
impl<F, H, M, T> Map<F> for Cons<H, Cons<M, T>>
where
Cons<(), T>: Map<Cons<(), ()>>,
{}
impl<F, H, T> Map<F> for Cons<H, T> {} I don't expect this to compile (in difference with original example), though the error should definitely be
instead of
|
The current tool chain:
compiles the original code with just a warning:
So no overflow or other error, I think this issue can be closed. |
Indeed, the issue seems to be fixed. Still, it'd be interesting to see which PR fixed the issue, and add test(s) in case the PR which fixed this did not have similar tests already. Tagging this issue appropriately. |
I tried this code:
I expected this code to compile.
Instead, the compiler fails with a huge error:
(playground)
Note that very similar code with a slightly different trait works, so I assume this is a bug (though, I may miss something)
Also, note that there is a lot of issues with
E0275
, however, I couldn't find one that fits my problem.Meta
Tested on
1.45.0
and1.47.0-nightly (2020-07-25 d6953df14657f5932270)
The text was updated successfully, but these errors were encountered: