From b15725aca59f78a631c1c6b6c28ce7342b5d985d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BB=A4=E7=8B=90=E4=B8=80=E5=86=B2?= <43949039+anonymousGiga@users.noreply.github.com> Date: Wed, 17 May 2023 14:00:15 +0800 Subject: [PATCH] Update chapter_3_4.md --- src/chapter_3/chapter_3_4.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/chapter_3/chapter_3_4.md b/src/chapter_3/chapter_3_4.md index 8485d17..46729f8 100644 --- a/src/chapter_3/chapter_3_4.md +++ b/src/chapter_3/chapter_3_4.md @@ -12,8 +12,9 @@ 代码注释有两种: -(1)行注释,使用“//” -(2)块注释,使用“/*... */” +(1)行注释,使用“//”; + +(2)块注释,使用“/*... */”。 示例如下: ``` @@ -41,6 +42,7 @@ fn main() { Rust提供了cargo doc命令可以把文档注释转换成html网页,最终展示给用户。文档注释也有文档行注释和文档块注释: (1)文档行注释,使用“///”; + (2)文档块注释,使用“/**...*/”。 示例如下: