Comments

Describes single-line comments, nestable block comments, and unclosed comment diagnostics.

Wave Foundation

one line comment

The content after // is a comment until the end of the line.

var count: i32 = 10;
// 현재 요청 수

block annotation

Process the space between /* and */ as a block comment.

/* 여러 줄에 걸친
   설명을 작성할 수 있습니다. */

You can nest other block comments within a block comment.

/* 바깥 주석
   /* 안쪽 주석 */
다시 바깥 주석
*/

Strings and Comment Marks

//, /*, and */ within string and character literals are string content and are not treated as the beginning or end of a comment.

var text: str = "https://wave-lang.dev";

Unclosed block comments

Failure to close the block comment with */ will result in the diagnosis E1002 UnterminatedComment.

Even when temporarily disabling long blocks, make sure the nesting depth is correct.