digitalmars.D - Problems with embedded code in ddoc
- FreeSlave (22/22) Sep 17 2020 I read this page https://dlang.org/spec/ddoc.html#embedded_code
- bachmeier (3/26) Sep 17 2020 Are you using the most recent beta, where markdown is supported
- bachmeier (2/4) Sep 17 2020 https://forum.dlang.org/post/omkkslyiefebwphugpkg@forum.dlang.org
- FreeSlave (4/6) Sep 17 2020 I'm using dmd 2.093.1
- David Gileadi (3/11) Sep 17 2020 Your version should support it with the -preview=markdown compiler flag....
- H. S. Teoh (10/12) Sep 17 2020 This is a problem. We seriously need to maintain at least two versions
I read this page https://dlang.org/spec/ddoc.html#embedded_code and noticed that backticks (`) and tildes (~) should be supported too when embedding code, but when I use dmd -D on my source it produces html without the block of code, but just text and actually tries to interpret <iostream> as html tag! Moreover if I change backticks to hyphens in the C++ code example, it produces Error: unmatched --- in DDoc comment So what's wrong? dmd ddox generator or the ddoc documentation? Here's the file I ran dmd -D on: /++ + Some C++ + ``` cpp + #include <iostream> + + void foo() + { + std::cout << "foo!"; + } + ``` +/ module main; void main() {}
Sep 17 2020
On Thursday, 17 September 2020 at 18:26:29 UTC, FreeSlave wrote:I read this page https://dlang.org/spec/ddoc.html#embedded_code and noticed that backticks (`) and tildes (~) should be supported too when embedding code, but when I use dmd -D on my source it produces html without the block of code, but just text and actually tries to interpret <iostream> as html tag! Moreover if I change backticks to hyphens in the C++ code example, it produces Error: unmatched --- in DDoc comment So what's wrong? dmd ddox generator or the ddoc documentation? Here's the file I ran dmd -D on: /++ + Some C++ + ``` cpp + #include <iostream> + + void foo() + { + std::cout << "foo!"; + } + ``` +/ module main; void main() {}Are you using the most recent beta, where markdown is supported by default?
Sep 17 2020
On Thursday, 17 September 2020 at 18:38:08 UTC, bachmeier wrote:Are you using the most recent beta, where markdown is supported by default?https://forum.dlang.org/post/omkkslyiefebwphugpkg forum.dlang.org
Sep 17 2020
On Thursday, 17 September 2020 at 18:38:08 UTC, bachmeier wrote:Are you using the most recent beta, where markdown is supported by default?I'm using dmd 2.093.1 Ok, I see, it's a new feature. I thought that spec docs on dlang.org correspond to the latest released version, not beta.
Sep 17 2020
On 9/17/20 11:47 AM, FreeSlave wrote:On Thursday, 17 September 2020 at 18:38:08 UTC, bachmeier wrote:Your version should support it with the -preview=markdown compiler flag. The next version removes the need for that flag.Are you using the most recent beta, where markdown is supported by default?I'm using dmd 2.093.1 Ok, I see, it's a new feature. I thought that spec docs on dlang.org correspond to the latest released version, not beta.
Sep 17 2020
On Thu, Sep 17, 2020 at 06:47:27PM +0000, FreeSlave via Digitalmars-d wrote: [..]I thought that spec docs on dlang.org correspond to the latest released version, not beta.This is a problem. We seriously need to maintain at least two versions of the spec on the website: the current (immutable) spec, and the upcoming spec (for the upcoming release). The (default) spec online should not reflect changes that haven't been released yet! Please file a bug for this if one hasn't already been filed. T -- I see that you JS got Bach.
Sep 17 2020