| error[E0435]: attempt to use a non-constant value in a constant |
| --> $DIR/invalid-const-operand.rs:56:26 |
| | |
| LL | asm!("{}", const x); |
| | ^ non-constant value |
| | |
| help: consider using `const` instead of `let` |
| | |
| LL - let x = 0; |
| LL + const x: /* Type */ = 0; |
| | |
| |
| error[E0435]: attempt to use a non-constant value in a constant |
| --> $DIR/invalid-const-operand.rs:59:36 |
| | |
| LL | asm!("{}", const const_foo(x)); |
| | ^ non-constant value |
| | |
| help: consider using `const` instead of `let` |
| | |
| LL - let x = 0; |
| LL + const x: /* Type */ = 0; |
| | |
| |
| error[E0435]: attempt to use a non-constant value in a constant |
| --> $DIR/invalid-const-operand.rs:62:36 |
| | |
| LL | asm!("{}", const const_bar(x)); |
| | ^ non-constant value |
| | |
| help: consider using `const` instead of `let` |
| | |
| LL - let x = 0; |
| LL + const x: /* Type */ = 0; |
| | |
| |
| error: invalid type for `const` operand |
| --> $DIR/invalid-const-operand.rs:16:19 |
| | |
| LL | global_asm!("{}", const 0f32); |
| | ^^^^^^---- |
| | | |
| | is an `f32` |
| | |
| = help: `const` operands must be of an integer or thin pointer type |
| |
| error: invalid type for `const` operand |
| --> $DIR/invalid-const-operand.rs:27:20 |
| | |
| LL | asm!("{}", const 0f32); |
| | ^^^^^^---- |
| | | |
| | is an `f32` |
| | |
| = help: `const` operands must be of an integer or thin pointer type |
| |
| error: invalid type for `const` operand |
| --> $DIR/invalid-const-operand.rs:31:20 |
| | |
| LL | asm!("{}", const b"Foo".as_slice()); |
| | ^^^^^^----------------- |
| | | |
| | is a `&[u8]` |
| | |
| = help: `const` operands must be of an integer or thin pointer type |
| |
| error: invalid type for `const` operand |
| --> $DIR/invalid-const-operand.rs:33:20 |
| | |
| LL | asm!("{}", const "Foo"); |
| | ^^^^^^----- |
| | | |
| | is a `&str` |
| | |
| = help: `const` operands must be of an integer or thin pointer type |
| |
| error: invalid type for `const` operand |
| --> $DIR/invalid-const-operand.rs:35:20 |
| | |
| LL | asm!("{}", const c"Foo"); |
| | ^^^^^^------ |
| | | |
| | is a `&CStr` |
| | |
| = help: `const` operands must be of an integer or thin pointer type |
| |
| error: aborting due to 8 previous errors |
| |
| For more information about this error, try `rustc --explain E0435`. |