]>
git.proxmox.com Git - rustc.git/blob - src/test/compile-fail/issue32829.rs
1 // Copyright 2016 The Rust Project Developers. See the COPYRIGHT
2 // file at the top-level directory of this distribution and at
3 // http://rust-lang.org/COPYRIGHT.
5 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8 // option. This file may not be copied, modified, or distributed
9 // except according to those terms.
11 // ignore-tidy-linelength
18 //~^ ERROR statements in constants are unstable
23 const bad_two
: u32 = {
26 //~^ ERROR statements in constants are unstable
27 //~^^ ERROR: calls in constants are limited to constant functions, tuple structs and tuple variants
32 const bad_three
: u32 = {
35 //~^ ERROR statements in constants are unstable
40 static bad_four
: u32 = {
43 //~^ ERROR statements in statics are unstable
48 static bad_five
: u32 = {
51 //~^ ERROR: calls in statics are limited to constant functions, tuple structs and tuple variants
52 //~| ERROR statements in statics are unstable
57 static bad_six
: u32 = {
60 //~^ ERROR statements in statics are unstable
65 static mut bad_seven
: u32 = {
68 //~^ ERROR statements in statics are unstable
73 static mut bad_eight
: u32 = {
76 //~^ ERROR statements in statics are unstable
77 //~| ERROR: calls in statics are limited to constant functions, tuple structs and tuple variants
82 static mut bad_nine
: u32 = {
85 //~^ ERROR statements in statics are unstable