1error: the `#[default]` attribute may only be used on unit enum variants 2 --> $DIR/macros-nonfatal-errors.rs:14:5 3 | 4LL | #[default] 5 | ^^^^^^^^^^ 6 7error: the `#[default]` attribute may only be used on unit enum variants 8 --> $DIR/macros-nonfatal-errors.rs:19:36 9 | 10LL | struct DefaultInnerAttrTupleStruct(#[default] ()); 11 | ^^^^^^^^^^ 12 13error: the `#[default]` attribute may only be used on unit enum variants 14 --> $DIR/macros-nonfatal-errors.rs:23:1 15 | 16LL | #[default] 17 | ^^^^^^^^^^ 18 19error: the `#[default]` attribute may only be used on unit enum variants 20 --> $DIR/macros-nonfatal-errors.rs:27:1 21 | 22LL | #[default] 23 | ^^^^^^^^^^ 24 25error: the `#[default]` attribute may only be used on unit enum variants 26 --> $DIR/macros-nonfatal-errors.rs:37:11 27 | 28LL | Foo = #[default] 0, 29 | ^^^^^^^^^^ 30 31error: the `#[default]` attribute may only be used on unit enum variants 32 --> $DIR/macros-nonfatal-errors.rs:38:14 33 | 34LL | Bar([u8; #[default] 1]), 35 | ^^^^^^^^^^ 36 37error: no default declared 38 --> $DIR/macros-nonfatal-errors.rs:43:10 39 | 40LL | #[derive(Default)] 41 | ^^^^^^^ 42 | 43 = help: make a unit variant default by placing `#[default]` above it 44 = note: this error originates in the derive macro `Default` (in Nightly builds, run with -Z macro-backtrace for more info) 45 46error: multiple declared defaults 47 --> $DIR/macros-nonfatal-errors.rs:49:10 48 | 49LL | #[derive(Default)] 50 | ^^^^^^^ 51... 52LL | Foo, 53 | --- first default 54LL | #[default] 55LL | Bar, 56 | --- additional default 57LL | #[default] 58LL | Baz, 59 | --- additional default 60 | 61 = note: only one variant can be default 62 = note: this error originates in the derive macro `Default` (in Nightly builds, run with -Z macro-backtrace for more info) 63 64error: `#[default]` attribute does not accept a value 65 --> $DIR/macros-nonfatal-errors.rs:61:5 66 | 67LL | #[default = 1] 68 | ^^^^^^^^^^^^^^ 69 | 70 = help: try using `#[default]` 71 72error: multiple `#[default]` attributes 73 --> $DIR/macros-nonfatal-errors.rs:69:5 74 | 75LL | #[default] 76 | ---------- `#[default]` used here 77LL | #[default] 78 | ---------- `#[default]` used again here 79LL | Foo, 80 | ^^^ 81 | 82 = note: only one `#[default]` attribute is needed 83help: try removing this 84 --> $DIR/macros-nonfatal-errors.rs:68:5 85 | 86LL | #[default] 87 | ^^^^^^^^^^ 88 89error: multiple `#[default]` attributes 90 --> $DIR/macros-nonfatal-errors.rs:79:5 91 | 92LL | #[default] 93 | ---------- `#[default]` used here 94LL | #[default] 95 | ---------- `#[default]` used again here 96... 97LL | Foo, 98 | ^^^ 99 | 100 = note: only one `#[default]` attribute is needed 101help: try removing these 102 --> $DIR/macros-nonfatal-errors.rs:76:5 103 | 104LL | #[default] 105 | ^^^^^^^^^^ 106LL | #[default] 107 | ^^^^^^^^^^ 108LL | #[default] 109 | ^^^^^^^^^^ 110 111error: the `#[default]` attribute may only be used on unit enum variants 112 --> $DIR/macros-nonfatal-errors.rs:86:5 113 | 114LL | Foo {}, 115 | ^^^ 116 | 117 = help: consider a manual implementation of `Default` 118 119error: default variant must be exhaustive 120 --> $DIR/macros-nonfatal-errors.rs:94:5 121 | 122LL | #[non_exhaustive] 123 | ----------------- declared `#[non_exhaustive]` here 124LL | Foo, 125 | ^^^ 126 | 127 = help: consider a manual implementation of `Default` 128 129error: asm template must be a string literal 130 --> $DIR/macros-nonfatal-errors.rs:99:10 131 | 132LL | asm!(invalid); 133 | ^^^^^^^ 134 135error: inline assembly must be a string literal 136 --> $DIR/macros-nonfatal-errors.rs:100:15 137 | 138LL | llvm_asm!(invalid); 139 | ^^^^^^^ 140 141error: concat_idents! requires ident args 142 --> $DIR/macros-nonfatal-errors.rs:102:5 143 | 144LL | concat_idents!("not", "idents"); 145 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 146 147error: argument must be a string literal 148 --> $DIR/macros-nonfatal-errors.rs:104:17 149 | 150LL | option_env!(invalid); 151 | ^^^^^^^ 152 153error: expected string literal 154 --> $DIR/macros-nonfatal-errors.rs:105:10 155 | 156LL | env!(invalid); 157 | ^^^^^^^ 158 159error: expected string literal 160 --> $DIR/macros-nonfatal-errors.rs:106:10 161 | 162LL | env!(foo, abr, baz); 163 | ^^^ 164 165error: environment variable `RUST_HOPEFULLY_THIS_DOESNT_EXIST` not defined 166 --> $DIR/macros-nonfatal-errors.rs:107:5 167 | 168LL | env!("RUST_HOPEFULLY_THIS_DOESNT_EXIST"); 169 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 170 | 171 = note: this error originates in the macro `env` (in Nightly builds, run with -Z macro-backtrace for more info) 172 173error: format argument must be a string literal 174 --> $DIR/macros-nonfatal-errors.rs:109:13 175 | 176LL | format!(invalid); 177 | ^^^^^^^ 178 | 179help: you might be missing a string literal to format with 180 | 181LL | format!("{}", invalid); 182 | +++++ 183 184error: argument must be a string literal 185 --> $DIR/macros-nonfatal-errors.rs:111:14 186 | 187LL | include!(invalid); 188 | ^^^^^^^ 189 190error: argument must be a string literal 191 --> $DIR/macros-nonfatal-errors.rs:113:18 192 | 193LL | include_str!(invalid); 194 | ^^^^^^^ 195 196error: couldn't read $DIR/i'd be quite surprised if a file with this name existed: $FILE_NOT_FOUND_MSG (os error 2) 197 --> $DIR/macros-nonfatal-errors.rs:114:5 198 | 199LL | include_str!("i'd be quite surprised if a file with this name existed"); 200 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 201 | 202 = note: this error originates in the macro `include_str` (in Nightly builds, run with -Z macro-backtrace for more info) 203 204error: argument must be a string literal 205 --> $DIR/macros-nonfatal-errors.rs:115:20 206 | 207LL | include_bytes!(invalid); 208 | ^^^^^^^ 209 210error: couldn't read $DIR/i'd be quite surprised if a file with this name existed: $FILE_NOT_FOUND_MSG (os error 2) 211 --> $DIR/macros-nonfatal-errors.rs:116:5 212 | 213LL | include_bytes!("i'd be quite surprised if a file with this name existed"); 214 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 215 | 216 = note: this error originates in the macro `include_bytes` (in Nightly builds, run with -Z macro-backtrace for more info) 217 218error: trace_macros! accepts only `true` or `false` 219 --> $DIR/macros-nonfatal-errors.rs:118:5 220 | 221LL | trace_macros!(invalid); 222 | ^^^^^^^^^^^^^^^^^^^^^^ 223 224error: aborting due to 27 previous errors 225 226