-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
ICE: feature(generic_const_exprs) enabled in one crate but not another #79018
Comments
@lcnr Hi, I would like to work on this. Which files should I look at to get started? |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
:/ closing this as somewhat intended.
I don't think there is much we can do here. This compiles if you change #![feature(const_evaluatable_checked)]
use what::{Const, Trait};
fn main() {
let _ = Const::<1>::assoc_fn();
} |
Ohh, of course. But surely this could produce an error instead of an ICE, no? |
This could, I don't know how to do that though 🤔 so yeah, let's keep that open for now |
This is almost impossible to emit a real error about. What we can do is add more text to the ICE |
Issue: rust-lang/rust#79018
Issue: rust-lang/rust#79018
This comment has been minimized.
This comment has been minimized.
Better error for normalization errors from parent crates that use `#![feature(generic_const_exprs)]` This PR implements a somewhat rudimentary heuristic to suggest using `#![feature(generic_const_exprs)]` in a child crate when a function from a foreign crate (that may have used `#![feature(generic_const_exprs)]`) fails to normalize during codegen. cc: rust-lang#79018 cc: rust-lang#94287
Better error for normalization errors from parent crates that use `#![feature(generic_const_exprs)]` This PR implements a somewhat rudimentary heuristic to suggest using `#![feature(generic_const_exprs)]` in a child crate when a function from a foreign crate (that may have used `#![feature(generic_const_exprs)]`) fails to normalize during codegen. cc: rust-lang#79018 cc: rust-lang#94287
Better error for normalization errors from parent crates that use `#![feature(generic_const_exprs)]` This PR implements a somewhat rudimentary heuristic to suggest using `#![feature(generic_const_exprs)]` in a child crate when a function from a foreign crate (that may have used `#![feature(generic_const_exprs)]`) fails to normalize during codegen. cc: rust-lang#79018 cc: rust-lang#94287
the ICE has been fixed in #94440 so I am going to close this issue. Don't think we need any additional tests for that PR. |
Extracted out from #78139 (comment), as that issue was closed but my case still ICEs
Given this code:
src/lib.rs
:examples/breakit.rs
:I get the following error:
Backtrace
It goes away when putting all of the code into one compilation unit.
The text was updated successfully, but these errors were encountered: