Skip to content

Doc: use conventional comment style in JavaScript examples#2320

Open
smorimoto wants to merge 1 commit into
masterfrom
doc/runtime-annotation-comment-style
Open

Doc: use conventional comment style in JavaScript examples#2320
smorimoto wants to merge 1 commit into
masterfrom
doc/runtime-annotation-comment-style

Conversation

@smorimoto

Copy link
Copy Markdown
Member

The manual consistently wrote runtime annotation comments without a space after // (e.g. //Provides:), and a couple of JavaScript examples used var. This updates the documentation to a more conventional style:

  • Use the spaced form // Provides: (and // Requires:, // Version:, etc.) for runtime annotations. Both forms are accepted by the linker; the spaced form is more idiomatic for JavaScript comments.
  • Use const instead of var in the JavaScript examples.

Only the documentation is touched (manual/*.mld, the Js.Unsafe.runtime_value doc comment, and a CHANGES.md entry). The runtime sources themselves are left unchanged.

Use the more conventional spaced form `// Provides:` (instead of `//Provides:`) for runtime annotations, and `const` (instead of `var`) in the manual and `Js.Unsafe.runtime_value` JavaScript examples.
@smorimoto

Copy link
Copy Markdown
Member Author

Related: ocamllabs/vscode-ocaml-platform#2162

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant