#tcl #proc #binding

tcl_derive

为tcl crate注册函数/闭包作为Tcl命令的宏

6个版本

0.1.5 2024年2月3日
0.1.4 2024年1月11日
0.1.3 2023年11月28日
0.1.2 2023年9月9日
0.1.0 2023年3月13日

#15 in #tcl

Download history 11/week @ 2024-03-11 15/week @ 2024-03-18 27/week @ 2024-04-01 142/week @ 2024-04-08 16/week @ 2024-04-22 10/week @ 2024-04-29 5/week @ 2024-05-13 22/week @ 2024-05-20 23/week @ 2024-05-27 16/week @ 2024-06-03 16/week @ 2024-06-10 14/week @ 2024-06-17 19/week @ 2024-06-24

每月下载量65
用于 4 个crate (2直接)

MIT/Apache

46KB
640

tcl_derive crate为tcl crate提供proc-macro实现。

  1. 使用#[proc]属性使Rust fn准备注册为Tcl命令。

  2. 使用tclfn!{}宏定义Rust fn并将其注册为Tcl命令。

  3. 使用tclosure!{}宏定义Rust闭包并将其注册为Tcl命令。

更多信息请参阅tcl crate的文档

许可证

根据Apache License 2.0或MIT License,任选其一。


lib.rs:

tcl(和tk)的过程宏

依赖项

~0.5–1MB
~22K SLoC