我使用的 doxygen 设置非常适合类、结构和命名空间,但不会为独立函数生成任何文档。
例如,这些方法不会生成任何内容:
#ifndef STRING_UTILS_H
#define STRING_UTILS_H 1
/// @file
/// @brief Trim whitespace from the start of the string
/// @param s - The string to left trim
/// @return the trimmed string
std::string ltrim(const std::string& s);
/// @brief Trim whitespace from the end of the string
/// @param s - The string to right trim
/// @return the trimmed string
std::string rtrim(const std::string& s);
/// @brief Trim whitespace from both sides of the string
/// @param s - The string to trim
/// @return the trimmed string
std::string trim(const std::string& s);
#endif
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
2017 次 |
| 最近记录: |