diff options
| author | Ralf Jung <post@ralfj.de> | 2020-05-18 08:48:45 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-05-18 08:48:45 +0200 |
| commit | 2cff5d961aa67693f0500d59f5d8607efaea9fdd (patch) | |
| tree | 73891f3a1dfb4e03617dfa5432b256b8eae5a3f1 /src/libstd | |
| parent | 2a9066479859f4aa22a08c71cd03f9b06ec99b7c (diff) | |
| parent | 3f47d9d2e6195babf10b4063deb504a00aa5d249 (diff) | |
| download | rust-2cff5d961aa67693f0500d59f5d8607efaea9fdd.tar.gz rust-2cff5d961aa67693f0500d59f5d8607efaea9fdd.zip | |
Rollup merge of #72307 - hermitcore:condvar, r=Mark-Simulacrum
use the new interface to initialize conditional variables HermitCore introduce a new interface to intialize conditional variables. Consequently, minor changes are required to support this interface.
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/Cargo.toml | 2 | ||||
| -rw-r--r-- | src/libstd/sys/hermit/condvar.rs | 4 |
2 files changed, 2 insertions, 4 deletions
diff --git a/src/libstd/Cargo.toml b/src/libstd/Cargo.toml index 923d5fa8cac..077ca2a2faa 100644 --- a/src/libstd/Cargo.toml +++ b/src/libstd/Cargo.toml @@ -41,7 +41,7 @@ dlmalloc = { version = "0.1", features = ['rustc-dep-of-std'] } fortanix-sgx-abi = { version = "0.3.2", features = ['rustc-dep-of-std'] } [target.'cfg(all(any(target_arch = "x86_64", target_arch = "aarch64"), target_os = "hermit"))'.dependencies] -hermit-abi = { version = "0.1.12", features = ['rustc-dep-of-std'] } +hermit-abi = { version = "0.1.13", features = ['rustc-dep-of-std'] } [target.wasm32-wasi.dependencies] wasi = { version = "0.9.0", features = ['rustc-dep-of-std'], default-features = false } diff --git a/src/libstd/sys/hermit/condvar.rs b/src/libstd/sys/hermit/condvar.rs index 5b7f16ce562..94e3275448a 100644 --- a/src/libstd/sys/hermit/condvar.rs +++ b/src/libstd/sys/hermit/condvar.rs @@ -12,9 +12,8 @@ impl Condvar { Condvar { identifier: 0 } } - #[inline] pub unsafe fn init(&mut self) { - // nothing to do + let _ = abi::init_queue(self.id()); } pub unsafe fn notify_one(&self) { @@ -50,7 +49,6 @@ impl Condvar { ret } - #[inline] pub unsafe fn destroy(&self) { let _ = abi::destroy_queue(self.id()); } |
