diff options
author | 2020-04-24 13:53:11 -0700 | |
---|---|---|
committer | 2020-04-24 13:53:11 -0700 | |
commit | 7dfc9751ee1c13a863074fe693fb01c8716ab5c3 (patch) | |
tree | 449ce71f8605179d08e23e566d7a7677afa229e6 /src/task.rs | |
parent | 5230e09a05b44ae9993d1e1c72be9abf0f689428 (diff) | |
download | rust-x86-7dfc9751ee1c13a863074fe693fb01c8716ab5c3.tar.gz rust-x86-7dfc9751ee1c13a863074fe693fb01c8716ab5c3.tar.zst rust-x86-7dfc9751ee1c13a863074fe693fb01c8716ab5c3.zip |
llvm_asm! instead of asm! to compile on nightly.
Diffstat (limited to 'src/task.rs')
-rw-r--r-- | src/task.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/task.rs b/src/task.rs index e71ea8f..40fdc2c 100644 --- a/src/task.rs +++ b/src/task.rs @@ -6,11 +6,11 @@ pub use crate::segmentation; /// Returns the current value of the task register. pub fn tr() -> segmentation::SegmentSelector { let segment: u16; - unsafe { asm!("str $0" : "=r" (segment) ) }; + unsafe { llvm_asm!("str $0" : "=r" (segment) ) }; segmentation::SegmentSelector::from_raw(segment) } /// Loads the task register. pub unsafe fn load_tr(sel: segmentation::SegmentSelector) { - asm!("ltr $0" :: "r" (sel.bits())); + llvm_asm!("ltr $0" :: "r" (sel.bits())); } |