> For the complete documentation index, see [llms.txt](https://docs.cheddar.vihan.org/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cheddar.vihan.org/docs/literals/comment.md).

# Comment

Comments are sections of code which are ignored by the interpreter. You may use them to write notes **describing** your code or to aid people reading your code in **understanding** it.

Cheddar has **C-style** comments, you can delimit a comment either with `//` or `/* .. */`:

Comments can go wherever **whitespace can go**. This means comments do not work within strings.

A single-line comment `//`, starts at any point in the line and continues until either a new line or the EOF (end of file).

```php
// Hello, World! This is my comment
```

Multiline comments are a little more special. They support *nested* comments which will elaborated more on. They will span until a matching `*/` has been found or the EOF.

```c
/*
Hello, this is my multi-line comment.
I can use this to quickly mark out blocks of code
or to just write longer messages.
*/
```

```c
/*
This comment does not have an ending,
 but it will work.
This is because comments will continue to
 the EOF if it can't find a `/*`
```

```c
/*
This is an example of nested comments.

If there is  another multiline comment
 within this one. It won't close this comment

  /*
   This is another coment
  */

This comment is still going as the previous `*​/`
did not close this comment.
 Note: the `*​/` before has a zero-width space
   between the * and /.
   This is why the comment didn't end

*/
```

> ## Note::Stability
>
> Nested block comments may not work at the moment. If you encounter any problems, please report the given source code on github and it'll (hopefully) be fixed promptly.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cheddar.vihan.org/docs/literals/comment.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
