Skip to content

Immutable classes aren't considered implicitly copyable #2550

@pcwalton

Description

@pcwalton

Failing testcase:

class C {
    let x: uint;

    new(x: uint) {
        self.x = x;
    }
}

fn f<T:copy>(x: T) {
}

fn main() {
    f(C(1u));
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions