//[<module>_includes ... //] 是什么注释约定?
What comment convention is //[<module>_includes ... //]?
boost::property_tree tutorial 包含一个明显的注释约定:
//[debug_settings_includes
#include ...
//]
//[debug_settings_data
struct debug_settings {...};
//]
//[debug_settings_load
void debug_settings::load(const std::string &filename) {...}
//]
//[debug_settings_save
void debug_settings::save(const std::string &filename) {...}
//]
int main() {...}
它只是一个 emacs 组织模式约定吗?是否有利用此约定的工具?采用并拥抱它会充实我的生活吗?
好像是文档生成的一部分。
例如,如果您看到 the raw source for the tutorial documentation,您会看到包含诸如
之类的行
First we need some includes:
[debug_settings_includes]
To store the logging configuration in the program we create a debug_settings
structure:
[debug_settings_data]
方括号内的线在the example source file.
中有相应的部分
并且在查看 the documentation itself 时,我们看到那些 "keywords" 已被源文件中的代码替换。
有关详细信息,请阅读 the Boost quickbook documentation。
boost::property_tree tutorial 包含一个明显的注释约定:
//[debug_settings_includes
#include ...
//]
//[debug_settings_data
struct debug_settings {...};
//]
//[debug_settings_load
void debug_settings::load(const std::string &filename) {...}
//]
//[debug_settings_save
void debug_settings::save(const std::string &filename) {...}
//]
int main() {...}
它只是一个 emacs 组织模式约定吗?是否有利用此约定的工具?采用并拥抱它会充实我的生活吗?
好像是文档生成的一部分。
例如,如果您看到 the raw source for the tutorial documentation,您会看到包含诸如
之类的行First we need some includes:
[debug_settings_includes]
To store the logging configuration in the program we create a debug_settings
structure:
[debug_settings_data]
方括号内的线在the example source file.
中有相应的部分并且在查看 the documentation itself 时,我们看到那些 "keywords" 已被源文件中的代码替换。
有关详细信息,请阅读 the Boost quickbook documentation。