about summary refs log tree commit diff
path: root/src/libstd/sys
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2020-05-18 08:48:45 +0200
committerGitHub <noreply@github.com>2020-05-18 08:48:45 +0200
commit2cff5d961aa67693f0500d59f5d8607efaea9fdd (patch)
tree73891f3a1dfb4e03617dfa5432b256b8eae5a3f1 /src/libstd/sys
parent2a9066479859f4aa22a08c71cd03f9b06ec99b7c (diff)
parent3f47d9d2e6195babf10b4063deb504a00aa5d249 (diff)
downloadrust-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/sys')
-rw-r--r--src/libstd/sys/hermit/condvar.rs4
1 files changed, 1 insertions, 3 deletions
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());
     }