Skip to content

Conversation

unicornx
Copy link
Contributor

@unicornx unicornx commented Oct 9, 2025

本 PR 包含两个 commit,分别修复了两个使用 doxygen 1.9.8 build 时发现的一些错误,这些问题使用 doxygen 1.9.1 构建时没有报错。ubuntu 22.04 默认安装的是 doxygen 1.9.1,但 ubunttu 24.04 默认安装的是 doxygen 1.9.8。

  • doxygen: remove @return command if function return void:如果一个函数返回值是 void,则不要写 @return
  • doxygen: fixed a minor typo for uart doc: 一个小的笔误,在 1.9.1 上构建和显示正常,但是 1.9.8 会报错。

When doxygen is upgraded to v1.9.8 (on ubuntu 24.04), doxygen
reports: "doxygen error: found documented return type for xxx
that does not return anything" for those functions which return
void but declare "@return" in doxygen comment.

Solution: remove "@return" for those cases, and update
guide document for how to write doxgen comment for functions.

Signed-off-by: Chen Wang <[email protected]>
This error is found when building with doxygen 1.9.8, but not
detecetd on 1.9.1.

Signed-off-by: Chen Wang <[email protected]>
Copy link

github-actions bot commented Oct 9, 2025

📌 Code Review Assignment

🏷️ Tag: components

Reviewers: @Maihuanyi

Changed Files (Click to expand)
  • components/drivers/audio/dev_audio.c
  • components/drivers/include/drivers/dev_can.h

🏷️ Tag: documentation

Reviewers: @CXSforHPU @GorrayLi @lianux-mm @unicornx

Changed Files (Click to expand)
  • documentation/0.doxygen/example/src/function.c
  • documentation/6.components/device-driver/uart/uart.md

📊 Current Review Status (Last Updated: 2025-10-09 15:10 CST)


📝 Review Instructions

  1. 维护者可以通过单击此处来刷新审查状态: 🔄 刷新状态
    Maintainers can refresh the review status by clicking here: 🔄 Refresh Status

  2. 确认审核通过后评论 LGTM/lgtm
    Comment LGTM/lgtm after confirming approval

  3. PR合并前需至少一位维护者确认
    PR must be confirmed by at least one maintainer before merging

ℹ️ 刷新CI状态操作需要具备仓库写入权限。
ℹ️ Refresh CI status operation requires repository Write permission.

Copy link

github-actions bot commented Oct 9, 2025

👋 感谢您对 RT-Thread 的贡献!Thank you for your contribution to RT-Thread!

为确保代码符合 RT-Thread 的编码规范,请在你的仓库中执行以下步骤运行代码格式化工作流(如果格式化CI运行失败)。
To ensure your code complies with RT-Thread's coding style, please run the code formatting workflow by following the steps below (If the formatting of CI fails to run).


🛠 操作步骤 | Steps

  1. 前往 Actions 页面 | Go to the Actions page
    点击进入工作流 → | Click to open workflow →

  2. 点击 Run workflow | Click Run workflow

  • 设置需排除的文件/目录(目录请以"/"结尾)
    Set files/directories to exclude (directories should end with "/")
  • 将目标分支设置为 \ Set the target branch to:dev-doxygen-fix-return
  • 设置PR number为 \ Set the PR number to:10768
  1. 等待工作流完成 | Wait for the workflow to complete
    格式化后的代码将自动推送至你的分支。
    The formatted code will be automatically pushed to your branch.

完成后,提交将自动更新至 dev-doxygen-fix-return 分支,关联的 Pull Request 也会同步更新。
Once completed, commits will be pushed to the dev-doxygen-fix-return branch automatically, and the related Pull Request will be updated.

如有问题欢迎联系我们,再次感谢您的贡献!💐
If you have any questions, feel free to reach out. Thanks again for your contribution!

@unicornx unicornx changed the title Dev doxygen fix return doxygen: fix two issues when building with doxygen 1.9.8 Oct 9, 2025
@unicornx unicornx requested review from Rbb666 and removed request for Cathy-lulu and mysterywolf October 9, 2025 07:11
@supperthomas supperthomas requested a review from Copilot October 10, 2025 02:00
Copy link
Contributor

@Copilot Copilot AI left a 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 fixes two documentation issues that cause errors when building with Doxygen 1.9.8, while these issues don't appear with Doxygen 1.9.1. The changes ensure compatibility with newer Doxygen versions.

  • Remove @return void commands from functions that return void, as Doxygen 1.9.8 treats this as an error
  • Fix a minor typo in UART documentation that causes build errors in Doxygen 1.9.8

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
documentation/6.components/device-driver/uart/uart.md Fixes typo in backtick formatting for RT_DEVICE_FLAG_STREAM documentation
documentation/0.doxygen/example/src/function.c Updates documentation guidelines and removes @return void from example
components/drivers/include/drivers/dev_can.h Removes @return void from rt_hw_can_isr function documentation
components/drivers/audio/dev_audio.c Removes @return void from two function documentations

@supperthomas supperthomas merged commit 273185b into RT-Thread:master Oct 10, 2025
57 checks passed
@unicornx unicornx deleted the dev-doxygen-fix-return branch October 11, 2025 02:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants