Skip to content

Vec::with_capacity(u64) panics when built #38277

@JesperAxelsson

Description

@JesperAxelsson

Vec::with_capacity(u64) panics.
Error message:

rustc main.rs -v
error: internal compiler error: ../src/librustc_typeck\check/mod.rs:4396: unexpected definition: PrimTy(TyUint(u64))

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

thread 'rustc' panicked at 'Box<Any>', ../src/librustc_errors/lib.rs:423
note: Run with `RUST_BACKTRACE=1` for a backtrace.

Minimal program:
fn main() { let vec = Vec::with_capacity(u64); }

Activity

added
I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
on Dec 10, 2016
Stebalien

Stebalien commented on Dec 10, 2016

@Stebalien
Contributor

Duplicate of #38155 and #38188, fixed in #38154. /cc @petrochenkov

steveklabnik

steveklabnik commented on Dec 14, 2016

@steveklabnik
Member

Closing as a duplicate, thank you!

added a commit that references this issue on Dec 15, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      Participants

      @steveklabnik@Stebalien@JesperAxelsson

      Issue actions

        Vec::with_capacity(u64) panics when built · Issue #38277 · rust-lang/rust