Skip to content

Segfault on trivial consumption of vector #4878

Closed
@alexcrichton

Description

@alexcrichton

This program will cause a segfault:

fn main() {
  let a : ~[int] = ~[];
  do a.consume |_, _| {}
}

Although if the consumption is changed to vec::consume the segfault does not happen.

This may be a dup of #4318?

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-codegenArea: Code generationI-crashIssue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions