-
Notifications
You must be signed in to change notification settings - Fork 5.3k
[rust] Tidy core defaults and migrate docs to README #11056
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
👋 感谢您对 RT-Thread 的贡献!Thank you for your contribution to RT-Thread! 为确保代码符合 RT-Thread 的编码规范,请在你的仓库中执行以下步骤运行代码格式化工作流(如果格式化CI运行失败)。 🛠 操作步骤 | Steps
完成后,提交将自动更新至 如有问题欢迎联系我们,再次感谢您的贡献!💐 |
📌 Code Review Assignment🏷️ Tag: componentsReviewers: @Maihuanyi Changed Files (Click to expand)
📊 Current Review Status (Last Updated: 2025-12-13 21:53 CST)
📝 Review Instructions
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR tidies up the Rust component defaults and migrates documentation to dedicated README files. The changes include code improvements, naming clarifications, bug fixes, and comprehensive documentation organization.
Key Changes:
- Fixed attribute syntax from
#[unsafe(no_mangle)]to#[no_mangle)]to match current Rust standards - Corrected a bug in
dlclosereturn value checking (changed fromrc == 1torc == 0) - Improved naming: thread default name from "uname" to "Unnamed", and enum variant from
FuncUnDefinetoFuncUndefined - Added comprehensive bilingual (English/Chinese) README documentation across all component subdirectories
Reviewed changes
Copilot reviewed 5 out of 16 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| components/rust/examples/modules/example_lib/src/lib.rs | Removed deprecated unsafe keyword from #[no_mangle] attributes |
| components/rust/core/src/panic.rs | Updated panic handler attribute syntax to current Rust standard |
| components/rust/core/src/thread.rs | Improved default thread name from "uname" to "Unnamed" |
| components/rust/core/src/lib.rs | Fixed spelling in error enum variant name |
| components/rust/core/src/api/libloading.rs | Corrected dlclose return value check logic |
| components/rust/docs/5.rt-macro/README_zh.md | Added Chinese documentation for rt_macros usage |
| components/rust/docs/5.rt-macro/README.md | Added English documentation for rt_macros usage |
| components/rust/docs/4.modules/README_zh.md | Added Chinese guide for dynamic module development |
| components/rust/docs/4.modules/README.md | Added English guide for dynamic module development |
| components/rust/docs/3.components/README_zh.md | Added Chinese component development documentation |
| components/rust/docs/3.components/README.md | Added English component development documentation |
| components/rust/docs/2.applications/README_zh.md | Added Chinese application examples documentation |
| components/rust/docs/2.applications/README.md | Added English application examples documentation |
| components/rust/docs/1.tools/README_zh.md | Added Chinese tools configuration documentation |
| components/rust/docs/1.tools/README.md | Added English tools configuration documentation |
| components/rust/README_zh.md | Added comprehensive Chinese README for the entire Rust component |
拉取/合并请求描述:(PR description)
[
为什么提交这份PR (why to submit this PR)
对rust组件进行整理,并统一风格。
你的解决方案是什么 (what is your solution)
对文件名进行调整,同时对代码进行复核。
请提供验证的bsp和config (provide the config and bsp)
]
当前拉取/合并请求的状态 Intent for your PR
必须选择一项 Choose one (Mandatory):
代码质量 Code Quality:
我在这个拉取/合并请求中已经考虑了 As part of this pull request, I've considered the following:
#if 0代码,不包含已经被注释了的代码 All redundant code is removed and cleaned up