codegen:Rust库,提供用于生成Rust代码的构建器API

上传者: 42118011 | 上传时间: 2023-06-25 17:53:08 | 文件大小: 24KB | 文件类型: ZIP
编码原 提供一个构建器API,以协助生成Rust代码。 有关此板条箱的更多信息,请参见 安装 要使用codegen ,首先将其添加到您的Cargo.toml : [ dependencies ] codegen = " 0.1.3 " 接下来,将其添加到您的板条箱中: extern crate codegen; 用法 创建一个Scope实例。 使用构建器API将元素添加到范围。 调用Scope::to_string()以获取生成的代码。 例如: use codegen :: Scope; let mut scope = Scope :: new (); scope. new_struct ( "Foo" ) . derive ( "Debug" ) . field ( "one" , "usize" ) . field ( "two" , "Stri

文件下载

资源详情

[{"title":"( 28 个子文件 24KB ) codegen:Rust库,提供用于生成Rust代码的构建器API","children":[{"title":"codegen-master","children":[{"title":".gitignore <span style='color:#111;'> 18B </span>","children":null,"spread":false},{"title":"src","children":[{"title":"item.rs <span style='color:#111;'> 339B </span>","children":null,"spread":false},{"title":"field.rs <span style='color:#111;'> 1.02KB </span>","children":null,"spread":false},{"title":"import.rs <span style='color:#111;'> 508B </span>","children":null,"spread":false},{"title":"function.rs <span style='color:#111;'> 6.91KB </span>","children":null,"spread":false},{"title":"struct.rs <span style='color:#111;'> 3.08KB </span>","children":null,"spread":false},{"title":"scope.rs <span style='color:#111;'> 9.22KB </span>","children":null,"spread":false},{"title":"impl.rs <span style='color:#111;'> 3.84KB </span>","children":null,"spread":false},{"title":"block.rs <span style='color:#111;'> 1.67KB </span>","children":null,"spread":false},{"title":"associated_type.rs <span style='color:#111;'> 361B </span>","children":null,"spread":false},{"title":"module.rs <span style='color:#111;'> 4.87KB </span>","children":null,"spread":false},{"title":"type_def.rs <span style='color:#111;'> 3.30KB </span>","children":null,"spread":false},{"title":"trait.rs <span style='color:#111;'> 3.52KB </span>","children":null,"spread":false},{"title":"docs.rs <span style='color:#111;'> 426B </span>","children":null,"spread":false},{"title":"variant.rs <span style='color:#111;'> 1.01KB </span>","children":null,"spread":false},{"title":"bound.rs <span style='color:#111;'> 119B </span>","children":null,"spread":false},{"title":"formatter.rs <span style='color:#111;'> 3.44KB </span>","children":null,"spread":false},{"title":"type.rs <span style='color:#111;'> 2.17KB </span>","children":null,"spread":false},{"title":"body.rs <span style='color:#111;'> 383B </span>","children":null,"spread":false},{"title":"enum.rs <span style='color:#111;'> 2.34KB </span>","children":null,"spread":false},{"title":"fields.rs <span style='color:#111;'> 2.61KB </span>","children":null,"spread":false},{"title":"lib.rs <span style='color:#111;'> 1.19KB </span>","children":null,"spread":false}],"spread":false},{"title":".travis.yml <span style='color:#111;'> 1012B </span>","children":null,"spread":false},{"title":"LICENSE <span style='color:#111;'> 1.03KB </span>","children":null,"spread":false},{"title":"CHANGELOG.md <span style='color:#111;'> 576B </span>","children":null,"spread":false},{"title":"Cargo.toml <span style='color:#111;'> 520B </span>","children":null,"spread":false},{"title":"README.md <span style='color:#111;'> 1.28KB </span>","children":null,"spread":false},{"title":"tests","children":[{"title":"codegen.rs <span style='color:#111;'> 10.99KB </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}]

评论信息

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明