Rise Chen
Rise Chen
```rust #[derive(Debug, Clone, Copy, PartialEq, Eq)] #[repr(align(2))] pub enum Test { A, B(u8), } ``` `Test::A` maybe is 0x0000 or 0xXX00, so it maybe not equal when transmute to u16.
``` rust #[derive(Debug, Clone, Copy, PartialEq, Eq)] pub struct Test { a: u8, b: u8, c: u8, d: u8, } fn main() { println!("align: {}", core::mem::align_of::()); println!("size: {}", core::mem::size_of::()); }...
I tried this code: ```rust #[async_trait] pub trait ConnectionDriver { ... } impl fmt::Debug for dyn ConnectionDriver { fn fmt(&self, f: &mut fmt::Formatter
#152 But, I don't think `SerializeToLua` and `DeserializeFromLua` is a good idea. I expect `fn add_one(_: &Lua, arg: Test) -> LuaResult` rather than `fn add_one(_: &Lua, arg: DeserializeFromLua) -> LuaResult`.
```rust use core::time::Duration; use mlua::prelude::*; async fn sleep LuaResult { tokio::time::sleep(Duration::from_secs(1)).await; Ok(()) } fn main() { let rt = tokio::runtime::Builder::new_current_thread() .enable_all() .build() .unwrap(); rt.spawn(async { loop { println!("hello"); tokio::time::sleep(Duration::from_secs(1)).await; }...
``` error: failed to run custom build command for `librocksdb-sys v6.20.3` Caused by: process didn't exit successfully: `/home/lebai/l-master-rc/target/debug/build/librocksdb-sys-d8cb22f39ddf0406/build-script-build` (exit status: 1) --- stdout cargo:rerun-if-changed=rocksdb/ TARGET = Some("x86_64-unknown-linux-gnu") OPT_LEVEL = Some("0")...
add RNG
Thanks for contributing to the project! Please write a short description of your changes. We also maintain a changelog in CHANGELOG.md. If you add a feature or fix a bug,...
Initialize the Tokio runtime with a custom Tokio runtime