www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - real beginner question about D's web site?

reply WhatMeWorry <kheaser gmail.com> writes:
https://github.com/dlang/dlang.org/blob/ff235feedcb2bcb73ba348dcd1763542a43c7778/doc.ddoc

D_S      = $(LAYOUT ,$1,$(ARGS $+))
SPEC_S   = $(LAYOUT ,$1,$(ARGS $+))
COMMUNITY= $(LAYOUT ,$1,$(ARGS $+))
_=
LAYOUT=$3
_=

I realize that D_S and LAYOUT, etc are macros. I've read the DDoc 
documentation and HTML, CSS, etc. but none of my research 
mentions the $ signs, as well as the $1 and $3. Am I missing 
something obvious?
Jan 24 2021
parent Adam D. Ruppe <destructionator gmail.com> writes:
On Sunday, 24 January 2021 at 20:05:47 UTC, WhatMeWorry wrote:
 mentions the $ signs, as well as the $1 and $3.
See point 4 here: https://dlang.org/spec/ddoc.html#macros $(THING ...) is a macro invocation. Inside the macro definition, $0 is the full text represented by "..." here. Then $1 is the text up to the first comma, $2 text from first to second comma, etc.
Jan 24 2021