-
Notifications
You must be signed in to change notification settings - Fork 13.3k
ICE on casting unsized tuple struct constructors. #50940
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
Labels
A-codegen
Area: Code generation
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Comments
I get this backtrace:
|
FWIW if llvm assertions are enabled the following assertion is hit. I'll start looking into this when I get some free cycles.
|
13 tasks
qnighy
added a commit
to qnighy/rust
that referenced
this issue
Nov 21, 2018
pietroalbini
added a commit
to pietroalbini/rust
that referenced
this issue
Nov 25, 2018
…ertj Check arg/ret sizedness at ExprKind::Path This PR solves three problems: - rust-lang#50940: ICE on casting unsized tuple struct constructors - Unsized tuple struct constructors were callable in presence of `unsized_locals`. - rust-lang#48055 (comment): we cannot relax `Sized` bounds on stable functions because of fn ptr casting These are caused by lack of `Sized`ness checks for arguments/retvals at **reference sites of `FnDef` items** (not call sites of the functions). Therefore we can basically add more `Sized` obligations on typeck. However, adding `Sized` obligations arbitrarily breaks type inference; to prevent that I added a new method `require_type_is_sized_deferred` which doesn't interfere usual type inference.
I think this issue can be closed. |
Yeah, I think I've fixed this in #56045. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-codegen
Area: Code generation
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
The following code causes ICE. playground
Stable
Nightly
The text was updated successfully, but these errors were encountered: