小编M.Z*_*yed的帖子

块注释开头的感叹号的用途是什么?

我有一个头文件c++,其中函数的声明具有以“ !”感叹号开头的块注释。

\n

例子

\n
class test{\n public:\n        /*! @fn test::test()\n            @brief The basic constructor, which initializes the _test handle.\n        */\n        test();\n\n        /*! @fn test::upload(std::string url)\n            @brief A function to execute a http POST request with the given url and image.\n\n            @param[in] url The url we are POSTing to\n            @return The response of the server\n        */\n        std::string upload(std::string url);\n}\n
Run Code Online (Sandbox Code Playgroud)\n

此外,它还会更改 VSCode 中注释的颜色,如下所示:

\n

在此输入图像描述

\n

这些注释开头的感叹号的目的是什么?

\n

c++ comments class

2
推荐指数
1
解决办法
648
查看次数

标签 统计

c++ ×1

class ×1

comments ×1