Properly support thin ptrs that are only thin due to their param-env in asm macro
This commit is contained in:
parent
bb029a1d3f
commit
04c00585c3
3 changed files with 16 additions and 5 deletions
12
tests/ui/asm/conditionally-sized-ptr.rs
Normal file
12
tests/ui/asm/conditionally-sized-ptr.rs
Normal file
|
@ -0,0 +1,12 @@
|
|||
//@ check-pass
|
||||
//@ needs-asm-support
|
||||
|
||||
use std::arch::asm;
|
||||
|
||||
fn _f<T>(p: *mut T) {
|
||||
unsafe {
|
||||
asm!("/* {} */", in(reg) p);
|
||||
}
|
||||
}
|
||||
|
||||
fn main() {}
|
Loading…
Add table
Add a link
Reference in a new issue