aboutsummaryrefslogtreecommitdiff
path: root/src/test/compile-fail/writing-to-immutable-obj.rs
blob: 4cdab570ad0dcbf26fa9fac81d4c686fb3b0961f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
// xfail-stage0
// xfail-stage1
// xfail-stage2
// error-pattern: writing to immutable type
obj objy(int x) {
    fn foo() -> () {
        x = 5;
    }
}
fn main() {
}