proposal: heredoc comments to allow `+/` in comments, eg from urls or documented unittests
Vladimir Panteleev
thecybershadow.lists at gmail.com
Sun Feb 11 08:26:54 UTC 2018
On Sunday, 11 February 2018 at 01:01:21 UTC, Jonathan M Davis
wrote:
> You could also always just declare a DDOC macro.
>
> Just put
>
> Macros:
> PLUS=+
>
> in the ddoc comment and then use $(PLUS) instead of +. It's
> more verbose that way given that PLUS isn't one of the standard
> ddoc macros, but it's more idiomatic to look at.
This won't work because URL linkification happens before macro
resolution, so $(PLUS) will break URLs. But you can of course
always use $(HTTP ...) or equivalent to emit a link explicitly.
More information about the Digitalmars-d
mailing list