forked from Orchid/orchid
updated all deps
migrated away from paste and async-std
This commit is contained in:
@@ -1,12 +1,9 @@
|
||||
use std::pin::pin;
|
||||
|
||||
use async_once_cell::OnceCell;
|
||||
use async_std::io::{self, Stdout};
|
||||
use async_std::sync::Mutex;
|
||||
use futures::lock::Mutex;
|
||||
use orchid_base::msg::{recv_msg, send_msg};
|
||||
|
||||
static STDOUT: OnceCell<Mutex<Stdout>> = OnceCell::new();
|
||||
|
||||
pub async fn send_parent_msg(msg: &[u8]) -> io::Result<()> {
|
||||
let stdout_lk = STDOUT.get_or_init(async { Mutex::new(io::stdout()) }).await;
|
||||
let mut stdout_g = stdout_lk.lock().await;
|
||||
|
||||
Reference in New Issue
Block a user