Adding Markdown to Ddoc
meppl
mephisto at nordhoff-online.de
Tue Dec 12 14:15:40 UTC 2017
On Tuesday, 12 December 2017 at 13:50:42 UTC, Bastiaan Veelo
wrote:
> On Tuesday, 12 December 2017 at 11:48:24 UTC, Chris wrote:
>> On Tuesday, 12 December 2017 at 11:33:45 UTC, Jonathan M Davis
>> wrote:
>>>
>>> And then you have to worry about something like int* screwing
>>> with things, because the compiler decides that you wanted
>>> italics. Honestly, I don't think that something like $(I foo)
>>> is very onerous - it's not all that different from <i>foo</i>
>>> or [i]foo[/i] (which plenty of folks are familiar with), but
>>> it's shorter and less visually noisy - and it doesn't risk
>>> having stuff that isn't supposed to be markdown being treated
>>> as markdown.
>>>
>>> [...]
>>
>> Try this one (paste it into
>> http://spec.commonmark.org/dingus/):
>>
>> # CommonMark
>>
>> ```
>> int* ptr;
>> ```
>> `int*` is a pointer to an integer.
>>
>> int* is a pointer to an integer.
>
> Coming up with a counter example is easy. Try this:
>
>> To dereference a pointer variable, write *i. To define a
>> pointer variable, write int* i.
>
> Inserting backticks obviously solves this and personally I
> would be fine with that requirement, but Markdown is not
> completely harmless. The above line comes out totally as not
> intended.
speaking of "harm". I would say there is not much harm when the
API-docs are broken at a certain place. Furthermore it is never
super difficult to fix. In comparison: Bugs in a programming
language are from a different world and super much more harmful
up to 9000.
More information about the Digitalmars-d
mailing list