1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387
|
error: allow, cfg, cfg_attr, deny, expect, forbid, and warn are the only allowed built-in attributes in function parameters
--> $DIR/invalid.rs:132:11
|
LL | fn barqux(#[rustc_force_inline] _x: u32) {}
| ^^^^^^^^^^^^^^^^^^^^^
error[E0805]: malformed `rustc_force_inline` attribute input
--> $DIR/invalid.rs:15:1
|
LL | #[rustc_force_inline(bar, baz)]
| ^^^^^^^^^^^^^^^^^^^^----------^
| |
| expected a single argument here
|
help: try changing it to one of the following valid forms of the attribute
|
LL - #[rustc_force_inline(bar, baz)]
LL + #[rustc_force_inline = "reason"]
|
LL - #[rustc_force_inline(bar, baz)]
LL + #[rustc_force_inline(reason)]
|
LL - #[rustc_force_inline(bar, baz)]
LL + #[rustc_force_inline]
|
error[E0539]: malformed `rustc_force_inline` attribute input
--> $DIR/invalid.rs:20:1
|
LL | #[rustc_force_inline(2)]
| ^^^^^^^^^^^^^^^^^^^^^-^^
| |
| expected a string literal here
|
help: try changing it to one of the following valid forms of the attribute
|
LL - #[rustc_force_inline(2)]
LL + #[rustc_force_inline = "reason"]
|
LL - #[rustc_force_inline(2)]
LL + #[rustc_force_inline(reason)]
|
LL - #[rustc_force_inline(2)]
LL + #[rustc_force_inline]
|
error[E0539]: malformed `rustc_force_inline` attribute input
--> $DIR/invalid.rs:25:1
|
LL | #[rustc_force_inline = 2]
| ^^^^^^^^^^^^^^^^^^^^^^^-^
| |
| expected a string literal here
|
help: try changing it to one of the following valid forms of the attribute
|
LL - #[rustc_force_inline = 2]
LL + #[rustc_force_inline = "reason"]
|
LL - #[rustc_force_inline = 2]
LL + #[rustc_force_inline(reason)]
|
LL - #[rustc_force_inline = 2]
LL + #[rustc_force_inline]
|
error: attribute should be applied to a function
--> $DIR/invalid.rs:30:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | extern crate std as other_std;
| ------------------------------ not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:34:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | use std::collections::HashMap;
| ------------------------------ not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:38:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | static _FOO: &'static str = "FOO";
| ---------------------------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:42:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | const _BAR: u32 = 3;
| -------------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:46:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | mod foo { }
| ----------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:50:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | / unsafe extern "C" {
LL | | #[rustc_force_inline]
LL | |
LL | | static X: &'static u32;
... |
LL | | fn foo();
LL | | }
| |_- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:66:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | type Foo = u32;
| --------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:70:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | / enum Bar<#[rustc_force_inline] T> {
LL | |
LL | | #[rustc_force_inline]
... |
LL | | }
| |_- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:72:10
|
LL | enum Bar<#[rustc_force_inline] T> {
| ^^^^^^^^^^^^^^^^^^^^^ - not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:74:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | Baz(std::marker::PhantomData<T>),
| -------------------------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:79:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | / struct Qux {
LL | | #[rustc_force_inline]
LL | |
LL | | field: u32,
LL | | }
| |_- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:82:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | field: u32,
| ---------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:87:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | / union FooBar {
LL | | x: u32,
LL | | y: u32,
LL | | }
| |_- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:94:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | / trait FooBaz {
LL | | #[rustc_force_inline]
LL | |
LL | | type Foo;
... |
LL | | fn foo() {}
LL | | }
| |_- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:109:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | trait FooQux = FooBaz;
| ---------------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:113:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | / impl<T> Bar<T> {
LL | | #[rustc_force_inline]
LL | |
LL | | fn foo() {}
LL | | }
| |_- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:121:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | / impl<T> FooBaz for Bar<T> {
LL | | type Foo = u32;
LL | | const Bar: i32 = 3;
LL | | }
| |_- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:128:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | macro_rules! barqux { ($foo:tt) => { $foo }; }
| ---------------------------------------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:132:11
|
LL | fn barqux(#[rustc_force_inline] _x: u32) {}
| ^^^^^^^^^^^^^^^^^^^^^--------
| |
| not a function definition
error: attribute cannot be applied to a `async`, `gen` or `async gen` function
--> $DIR/invalid.rs:136:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | async fn async_foo() {}
| -------------------- `async`, `gen` or `async gen` function
error: attribute cannot be applied to a `async`, `gen` or `async gen` function
--> $DIR/invalid.rs:140:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | gen fn gen_foo() {}
| ---------------- `async`, `gen` or `async gen` function
error: attribute cannot be applied to a `async`, `gen` or `async gen` function
--> $DIR/invalid.rs:144:1
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | async gen fn async_gen_foo() {}
| ---------------------------- `async`, `gen` or `async gen` function
error: attribute should be applied to a function
--> $DIR/invalid.rs:149:14
|
LL | let _x = #[rustc_force_inline] || { };
| ^^^^^^^^^^^^^^^^^^^^^ ------ not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:151:14
|
LL | let _y = #[rustc_force_inline] 3 + 4;
| ^^^^^^^^^^^^^^^^^^^^^ - not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:153:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | let _z = 3;
| ----------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:158:9
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | 1 => (),
| ------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:97:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | type Foo;
| --------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:100:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | const Bar: i32;
| --------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:104:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | fn foo() {}
| ----------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:116:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | fn foo() {}
| ----------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:53:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | static X: &'static u32;
| ----------------------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:57:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | type Y;
| ------- not a function definition
error: attribute should be applied to a function
--> $DIR/invalid.rs:61:5
|
LL | #[rustc_force_inline]
| ^^^^^^^^^^^^^^^^^^^^^
LL |
LL | fn foo();
| --------- not a function definition
error: aborting due to 37 previous errors
Some errors have detailed explanations: E0539, E0805.
For more information about an error, try `rustc --explain E0539`.
|