code-d
code-d copied to clipboard
Embedded Code preview incorrect - (` hyphens and /// blocks and comment openings)
The highlighting does not always work when tokens/characters are exchanged. Note: https://dlang.org/spec/ddoc.html#embedded_comments
- The example given by the page above, also given below, does not function when
```is used instead of---, even though````does. - Additionally, using
///instead of/++,+,+/breaks the spacing of the embeded coding preview. (https://dlang.org/spec/ddoc.html#lexical) - Comment openings are not ignored when the documentation starts on the same line as the initial comment line.
/++
+ Our function.
+
+ Example:
+ ---
+ import std.stdio;
+
+ void foo()
+ {
+ writeln("foo!"); /* print the string */
+ }
+ ---
+/
Expected result:

Modified results:
- replace
---with```
- replace
/++,+,+/with///
- documentation starts on the same line as the initial comment line
1 is fixed in serve-d now, (nightly available in 24h) 2 and 3 need updates to DCD and will take a while longer to be released.