summary refs log tree commit diff
path: root/src/test/ui/error-codes/E0388.rs
blob: 817f2554adef0387e7f01cedd6d1c844c695ac36 (plain)
1
2
3
4
5
6
7
8
9
10
static X: i32 = 1;
const C: i32 = 2;

const CR: &'static mut i32 = &mut C; //~ ERROR E0017
static STATIC_REF: &'static mut i32 = &mut X; //~ ERROR E0017
                                              //~| ERROR cannot borrow
                                              //~| ERROR cannot mutate statics
static CONST_REF: &'static mut i32 = &mut C; //~ ERROR E0017

fn main() {}