atri_bot
atri_bot copied to clipboard
A simple bot in rust running on various platforms
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.155 to 1.0.164. Release notes Sourced from serde's releases. v1.0.164 Allowed enum variants to be individually marked as untagged (#2403, thanks @dewert99) v1.0.163 Eliminate build script from...
Bumps [regex](https://github.com/rust-lang/regex) from 1.7.1 to 1.8.4. Changelog Sourced from regex's changelog. 1.8.4 (2023-06-05) This is a patch release that fixes a bug where (?-u:\B) was allowed in Unicode regexes, despite...
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.26.0 to 1.28.2. Release notes Sourced from tokio's releases. Tokio v1.28.2 1.28.2 (May 28, 2023) Forward ports 1.18.6 changes. Fixed deps: disable default features for mio (#5728)...
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.94 to 1.0.96. Release notes Sourced from serde_json's releases. v1.0.96 Guarantee that to_writer only writes valid UTF-8 strings (#1011, thanks @stepancheg) v1.0.95 Preserve f32 precision when serializing...
Bumps [async-trait](https://github.com/dtolnay/async-trait) from 0.1.66 to 0.1.68. Release notes Sourced from async-trait's releases. 0.1.68 Improve error message if an async fn is written without a function body in an impl block...
`AtriBot`内有很多Arc wrapper, 比如`Client`, `Group`, `Friend`... 他们的数据转移到插件的时候会先转换为`Managed`结构体 该转换包含了一次堆分配, 而`Arc`本身就是将数据存入堆中的(也就是变成了Box\) 考虑添加`ManagedArc`, 使用`Arc::into_raw`与`Arc::from_raw`, 减少堆分配(释放)
指令系统设想
# 指令系统 ### 单指令 单个可以执行的指令 ```rust #[command(name = "x", help="a")] async fn a(arg1: ..) -> Result { } ``` 调用方式: `/x arg1..` ### 复合指令 ```rust #[command(name = "x")] mod a...