Skip to content

Commit c7ce031

Browse files
committed
Add asm-goto to unstable book
1 parent 5bb0191 commit c7ce031

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# `asm_goto`
2+
3+
The tracking issue for this feature is: [#119364]
4+
5+
[#119364]: https://github.com/rust-lang/rust/issues/119364
6+
7+
------------------------
8+
9+
This feature adds a `label <block>` operand type to `asm!`.
10+
11+
Example:
12+
```rust,ignore (partial-example, x86-only)
13+
14+
unsafe {
15+
asm!(
16+
"jmp {}",
17+
label {
18+
println!("Jumped from asm!");
19+
}
20+
);
21+
}
22+
```
23+
24+
The block must have unit type.

0 commit comments

Comments
 (0)