添加Doxygen注释的示例
This commit is contained in:
		| @@ -3,6 +3,11 @@ | |||||||
| // | // | ||||||
| #include "example.h" | #include "example.h" | ||||||
|  |  | ||||||
|  | /** | ||||||
|  |  * @brief 在stdin打印一个字符串 | ||||||
|  |  *  | ||||||
|  |  * @param str 指向需要打印的字符串指针 | ||||||
|  |  */ | ||||||
| void print(char* str) | void print(char* str) | ||||||
| { | { | ||||||
|     printf("%s", str); |     printf("%s", str); | ||||||
|   | |||||||
							
								
								
									
										9
									
								
								main.c
									
									
									
									
									
								
							
							
						
						
									
										9
									
								
								main.c
									
									
									
									
									
								
							| @@ -1,7 +1,16 @@ | |||||||
| #include "example.h" | #include "example.h" | ||||||
|  |  | ||||||
|  | /** | ||||||
|  |  * @brief 程序的主函数 | ||||||
|  |  *  | ||||||
|  |  * @return int 程序结束的状态,0表示成功 | ||||||
|  |  */ | ||||||
| int main() | int main() | ||||||
| { | { | ||||||
|  |     /** | ||||||
|  |      * @brief 需要输出的字符串 | ||||||
|  |      *  | ||||||
|  |      */ | ||||||
|     char* string = "Good morning!\n"; |     char* string = "Good morning!\n"; | ||||||
|     print(string); |     print(string); | ||||||
|     return 0; |     return 0; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user