Skip to content

type parameter A/#0 (A/0) out of range when substituting (root type=Some(*const A)) substs=[] #65025

Closed
@gz

Description

@gz

Minimal example: https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=814876c654b0b3ad162d52ba64064b02

error: internal compiler error: src/librustc/ty/subst.rs:557: type parameter `A/#0` (A/0) out of range when substituting (root type=Some(*const A)) substs=[]

thread 'rustc' panicked at 'Box<Any>', src/librustc_errors/lib.rs:579:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
error: aborting due to previous error


note: the compiler unexpectedly panicked. this is a bug.

note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.38.0 (625451e37 2019-09-23) running on x86_64-unknown-linux-gnu

note: compiler flags: -C codegen-units=1 -C debuginfo=2 --crate-type bin

note: some of the compiler flags provided by cargo are hidden

error: Could not compile `playground`.

I'm on nightly but it also crashes on stable.

Metadata

Metadata

Assignees

Labels

A-FFIArea: Foreign function interface (FFI)A-type-systemArea: Type systemC-bugCategory: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️P-mediumMedium priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions