Documentation in V

Posted by yhuang
Public (Editable by Users)
V
None
Edit
// The way it works is very similar to Go. It's very simple: there's no need to write documentation for your code, vdoc will generate it from the source code.
// Documentation for each function/type/const must be placed right before the declaration:

// clearall clears all bits in the array
fn clearall() {
}
// The comment must start with the name of the definition.

// An overview of the module must be placed in the first comment right after the module's name.

// To generate documentation, run v doc path/to/module (TODO this is temporarily disabled).