Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

First shot at generating PDF via LaTeX

  • Loading branch information...
commit 1d4203a8dbabe9ecbc1a7f46a0b63b9a2743bfe0 1 parent 6e47a94
Andrei Alexandrescu authored January 08, 2013
3  const3.dd
@@ -314,7 +314,7 @@ $(SECTION2 Immutable Member Functions,
314 314
 	)
315 315
 
316 316
 ---
317  
-struct S {   
  317
+struct S {
318 318
   int x;
319 319
 
320 320
   void foo() immutable {
@@ -582,7 +582,6 @@ Macros:
582 582
 	NO1=<td class="compNo"><a href="$1">No</a></td>
583 583
 	YES=<td class="compYes">Yes</td>
584 584
 	YES1=<td class="compYes"><a href="$1">Yes</a></td>
585  
-	D_CODE = <pre class="d_code2">$0</pre>
586 585
 	CPPCODE2 = <pre class="cppcode2">$0</pre>
587 586
 	ERROR = $(RED $(B error))
588 587
 	COMMA=,
17  doc.ddoc
@@ -456,5 +456,18 @@ HTTPS = $(LINK2 https://$1,$2)
456 456
 LUCKY = $(HTTP
457 457
 google.com/search?btnI=I%27m+Feeling+Lucky&amp;ie=UTF-8&amp;oe=UTF-8&amp;q=$0,$0)
458 458
 
459  
-FOO=FOO
460  
-
  459
+ET=&amp;
  460
+CODE_ET=$(D &amp;)
  461
+GT=>
  462
+LT=<
  463
+REG=&copy;
  464
+H3=<h3>$0</h3>
  465
+H4=<h4>$0</h4>
  466
+CODE_LCURL=$(D {)
  467
+CODE_RCURL=$(D })
  468
+CODE_PERCENT=$(D %)
  469
+FULL_XREF=<a href="phobos/std_$1.html#$2">$(D std.$1.$2)</a>
  470
+DDOC_COMMENT=<!--$0-->
  471
+UNDERSCORE=_
  472
+TABLE_2COLS=$(TABLE2 $1, $+)
  473
+TROW_EXPLANATORY=<td colspan=10>$0</td>
1  intro-to-datetime.dd
@@ -773,7 +773,6 @@ Macros:
773 773
     CXREF = <a href="phobos/core_$1.html#$2">$(D $2)</a>
774 774
     FULL_CXREF = <a href="phobos/core_$1.html#$2">$(D core.$1.$2)</a>
775 775
     XREF = <a href="phobos/std_$1.html#$2">$(D $2)</a>
776  
-    FULL_XREF = <a href="phobos/std_$1.html#$2">$(D std.$1.$2)</a>
777 776
     CORE_TIME=<a href="phobos/core_time.html">$(D core.time)</a>
778 777
     STD_DATETIME=<a href="phobos/std_datetime.html">$(D std.datetime)</a>
779 778
     STD_DATE=<a href="phobos/std_date.html">$(D std.date)</a>
188  latex.ddoc
... ...
@@ -0,0 +1,188 @@
  1
+ET=\&
  2
+CODE_ET=$(D &)
  3
+GT=>
  4
+LT=<
  5
+REG=(c)
  6
+H3=\subsection{$0}
  7
+D=\lstinline|$0|
  8
+LCURL=LCURL
  9
+RCURL=RCURL
  10
+CODE_LCURL=\verb|{|
  11
+CODE_RCURL=\verb|}|
  12
+PERCENT=PERCENT
  13
+CODE_PERCENT=\verb|%|
  14
+FULL_XREF = <a href="phobos/std_$1.html#$2">$(D std.$1.$2)</a>
  15
+FULL_XREF=\href{phobos/std_$1.html#$2}{$(D std.$1.$2)}
  16
+DDOC_COMMENT=% $0
  17
+H4=\subsubsection{$0}
  18
+SINGLEQUOTE=`$0'
  19
+UNDERSCORE=\_
  20
+U=\underline{$0}
  21
+MIDRULE=\midrule
  22
+TROW_EXPLANATORY=$0\\
  23
+
  24
+DDOC=% Copyright (c) 1999-$(YEAR) by Digital Mars
  25
+% All Rights Reserved Written by Walter Bright
  26
+% http://www.digitalmars.com
  27
+
  28
+\documentclass[11pt]{article}
  29
+%\usepackage{color}
  30
+\usepackage[usenames,dvipsnames]{xcolor}
  31
+\usepackage{listings}
  32
+\usepackage{hyperref}
  33
+\usepackage{booktabs}
  34
+\usepackage{alltt}
  35
+\usepackage{tabularx}
  36
+
  37
+\def\commentstyle{%
  38
+  \color{OliveGreen}%
  39
+  \textsl%
  40
+}
  41
+\lstset{language=C++,basicstyle=\ttfamily,escapeinside={/*[}{]*/},commentstyle=\commentstyle,morecomment=[n]{/+}{+/},stringstyle=\color{BrickRed},keywordstyle=\color{NavyBlue}}
  42
+\lstset{morekeywords={@disable,   @property,
  43
+        @safe, @system, @trusted, abstract, alias, align, asm, assert,
  44
+        auto,  body, bool,  break, byte,  case, cast,  catch, cdouble,
  45
+        cent,  cfloat,  char, class,  const,  continue, creal,  dchar,
  46
+        debug,  default,  delegate,  delete, deprecated,  do,  double,
  47
+        else, enum, export, extern, false, final, finally, float, for,
  48
+        foreach, foreach_reverse, function, goto, idouble, if, ifloat,
  49
+        immutable,  import,  in,  inout,  int,  interface,  invariant,
  50
+        ireal, is, lazy, long, mixin, module, new, nothrow, null, out,
  51
+        override, package,  pragma, private, protected,  public, real,
  52
+        ref,  return,  scope, shared,  short,  static, struct,  super,
  53
+        switch,  synchronized,  template,   this,  throw,  true,  try,
  54
+        typedef,  typeid, typeof,  ubyte, ucent,  uint,  ulong, union,
  55
+        unittest,  ushort,  version,  void,  volatile,  wchar,  while,
  56
+        with,\#!, macro, pure, __FILE__, __LINE__, __gshared,
  57
+        __traits, __vector, __parameters}}
  58
+
  59
+\sloppy
  60
+\begin{document}
  61
+\title{D Programming Language Specification}
  62
+\date{}
  63
+\maketitle
  64
+
  65
+$(BODY)
  66
+\end{document}
  67
+
  68
+GOOGLE_FOOTER=
  69
+GOOGLE_REFERRAL=
  70
+FOOTER=
  71
+TOP=
  72
+NAVIGATION_COMMUNITY=
  73
+NAVIGATION_SPEC=
  74
+NAVIGATION_D=
  75
+BOOKS=
  76
+
  77
+TOCENTRY = $(LI $(LINK2 #$+, $+))
  78
+LAYOUT=
  79
+\section{$2}
  80
+  $3
  81
+
  82
+CODE=\lstinline{$0}
  83
+ASMCODE=\lstinline{$0}
  84
+CCODE=\lstinline{$0}
  85
+CPPCODE=\lstinline{$0}
  86
+GRAMMAR=\begin{alltt}
  87
+$0
  88
+\end{alltt}
  89
+GNAME={\fontshape{sl}\selectfont $0}
  90
+DDOCCODE=\lstinline{$0}
  91
+SCINI=\lstinline{$0}
  92
+CONSOLE=\lstinline{$0}
  93
+MODDEFFILE=\lstinline{$0}
  94
+
  95
+GLINK2=$(GLINK $2)
  96
+DDLINK=$(LINK2 #$2, $3)
  97
+DDSUBLINK=$(LINK2 #$2, $3)
  98
+DPLLINK=$(LINK2 http://dlang.org/$1, $2)
  99
+NOT_EBOOK=
  100
+
  101
+B=\textbf{$0}
  102
+I=\textit{$0}
  103
+U=\underline{$0}
  104
+P= $0 \par
  105
+
  106
+DL=\begin{description}
  107
+$0
  108
+\end{description}
  109
+DT=\item[$0]
  110
+DD=$0
  111
+TABLE=\begin{tabular}[2]{lllllllllll}
  112
+$0
  113
+\end{tabular}
  114
+TABLE_2COLS=\begin{center}
  115
+\begin{tabularx}{\textwidth}[2]{lXl}
  116
+$+
  117
+\bottomrule
  118
+\end{tabularx}
  119
+\end{center}
  120
+TABLE_3COLS=\begin{center}
  121
+\begin{tabularx}{\textwidth}[2]{lXXl}
  122
+$+
  123
+\bottomrule
  124
+\end{tabularx}
  125
+\end{center}
  126
+TABLE2=\begin{center}
  127
+\begin{tabular}[10]{lllllllllll}
  128
+$+
  129
+\bottomrule
  130
+\end{tabular}
  131
+\end{center}
  132
+TR=$0 \\
  133
+TH=$0 &
  134
+TD=$0
  135
+OL=\begin{enumerate}
  136
+$0
  137
+\end{enumerate}
  138
+UL=\begin{itemize}
  139
+$0
  140
+\end{itemize}
  141
+LI=\item $0
  142
+BIG=\large{$0}
  143
+SMALL=\small{$0}
  144
+BR=\newline
  145
+LINK=\url{$0}
  146
+LINK2=\href{$1}{$+}
  147
+RED={\color{red}$0}
  148
+BLUE={\color{blue}$0}
  149
+GREEN={\color{green}$0}
  150
+YELLOW={\color{yellow}$0}
  151
+BLACK={\color{black}$0}
  152
+WHITE={\color{white}$0}
  153
+D_CODE=\begin{lstlisting}
  154
+$0
  155
+\end{lstlisting}
  156
+
  157
+TRANSLATIONS=
  158
+
  159
+RED    = {\color{red}$0}
  160
+GREEN  = {\color{green}$0}
  161
+BLUE   = {\color{blue}$0}
  162
+YELLOW = {\color{yellow}$0}
  163
+ORANGE = {\color{orange}$0}
  164
+BLACK  = {\color{black}$0}
  165
+WHITE  = {\color{white}$0}
  166
+
  167
+COMMA=,
  168
+THX=& $1 $(THX $+)
  169
+TDX=& $1 $(TDX $+)
  170
+THEAD=\toprule $1 $(THX $+) \\ \midrule
  171
+TROW=$1 $(TDX $+) \\
  172
+LIX=\item{$1} $(LIX $+)
  173
+LIST=\begin{itemize}
  174
+$(LIX $1, $+)
  175
+\end{itemize}
  176
+LNAME2=$+
  177
+
  178
+D_COMMENT=$(GREEN $0)
  179
+D_STRING = $(RED $0)
  180
+D_KEYWORD = $(BLUE $0)
  181
+D_PSYMBOL = $(U $0)
  182
+D_PARAM = $(I $0)
  183
+
  184
+D_COMMENT=$0
  185
+D_STRING=$0
  186
+D_KEYWORD=$0
  187
+D_PSYMBOL = $(U $0)
  188
+D_PARAM = $(I $0)
674  lex.dd
@@ -11,7 +11,7 @@ $(SPEC_S Lexical,
11 11
 	for. The tokens are readily recognizable by those familiar with C and
12 12
 	C++.
13 13
 
14  
-<h3>Source Text</h3>
  14
+$(H3 Source Text)
15 15
 
16 16
 	D source text can be in one of the following formats:
17 17
 
@@ -48,7 +48,6 @@ $(SPEC_S Lexical,
48 48
 	$(P The source text is decoded from its source representation
49 49
 	into Unicode $(GLINK Character)s.
50 50
 	The $(GLINK Character)s are further divided into:
51  
-
52 51
 	$(GLINK WhiteSpace),
53 52
 	$(GLINK EndOfLine),
54 53
 	$(GLINK Comment)s,
@@ -60,47 +59,45 @@ $(SPEC_S Lexical,
60 59
 	$(P The source text is split into tokens using the maximal munch
61 60
 	technique, i.e., the
62 61
 	lexical analyzer tries to make the longest token it can. For example
63  
-	<code>&gt;&gt;</code> is a right shift token,
64  
-	not two greater than tokens. An exception to this rule is that a ..
  62
+	$(D $(GT)$(GT)) is a right shift token,
  63
+	not two greater than tokens. An exception to this rule is that a $(D ..)
65 64
 	embedded inside what looks like two floating point literals, as in
66  
-	1..2, is interpreted as if the .. was separated by a space from the
  65
+	$(D 1..2), is interpreted as if the $(D ..) was separated by a space from the
67 66
 	first integer.
68 67
 	)
69 68
 
70  
-<h3>Character Set</h3>
  69
+$(H3 Character Set)
71 70
 
72 71
 $(GRAMMAR
73  
-$(GNAME Character)
  72
+$(GNAME Character):
74 73
     $(I any Unicode character)
75 74
 )
76 75
 
77  
-<h3>End of File</h3>
  76
+$(H3 End of File)
78 77
 
79 78
 $(GRAMMAR
80 79
 $(GNAME EndOfFile):
81 80
     $(I physical end of the file)
82  
-    \u0000
83  
-    \u001A
84  
-)
  81
+    $(D \u0000)
  82
+    $(D \u001A))
85 83
 
86  
-	The source text is terminated by whichever comes first.
  84
+The source text is terminated by whichever comes first.
87 85
 
88  
-<h3>End of Line</h3>
  86
+$(H3 End of Line)
89 87
 
90 88
 $(GRAMMAR
91 89
 $(GNAME EndOfLine):
92  
-    \u000D
93  
-    \u000A
94  
-    \u000D \u000A
95  
-    \u2028
96  
-    \u2029
97  
-    $(GLINK EndOfFile)
98  
-)
  90
+    $(D \u000D)
  91
+    $(D \u000A)
  92
+    $(D \u000D \u000A)
  93
+    $(D \u2028)
  94
+    $(D \u2029)
  95
+    $(GLINK EndOfFile))
99 96
 
100 97
 	There is no backslash line splicing, nor are there any limits
101 98
 	on the length of a line.
102 99
 
103  
-<h3>White Space</h3>
  100
+$(H3 White Space)
104 101
 
105 102
 $(GRAMMAR
106 103
 $(GNAME WhiteSpace):
@@ -108,14 +105,14 @@ $(GNAME WhiteSpace):
108 105
     $(GLINK Space) $(I WhiteSpace)
109 106
 
110 107
 $(GNAME Space):
111  
-    \u0020
112  
-    \u0009
113  
-    \u000B
114  
-    \u000C
  108
+    $(D \u0020)
  109
+    $(D \u0009)
  110
+    $(D \u000B)
  111
+    $(D \u000C)
115 112
 )
116 113
 
117 114
 
118  
-<h3>$(LNAME2 comment, Comments)</h3>
  115
+$(H3 $(LNAME2 comment, Comments))
119 116
 
120 117
 $(GRAMMAR
121 118
 $(GNAME Comment):
@@ -123,10 +120,10 @@ $(GNAME Comment):
123 120
     $(GLINK LineComment)
124 121
     $(GLINK NestingBlockComment)
125 122
 
126  
-$(GNAME BlockComment)
  123
+$(GNAME BlockComment):
127 124
     $(B /*) $(GLINK Characters) $(B */)
128 125
 
129  
-$(GNAME LineComment)
  126
+$(GNAME LineComment):
130 127
     $(B //) $(GLINK Characters) $(GLINK EndOfLine)
131 128
 
132 129
 $(GNAME NestingBlockComment):
@@ -142,10 +139,9 @@ $(GNAME NestingBlockCommentCharacter):
142 139
 
143 140
 $(GNAME Characters):
144 141
     $(GLINK Character)
145  
-    $(GLINK Character) $(I Characters)
146  
-)
  142
+    $(GLINK Character) $(I Characters))
147 143
 
148  
-	$(P D has three kinds of comments:)
  144
+    $(P D has three kinds of comments:)
149 145
 
150 146
 	$(OL
151 147
 	$(LI Block comments can span multiple lines, but do not nest.)
@@ -169,10 +165,10 @@ a = /+ /* +/ */ 3; // parses as if 'a = */ 3;'
169 165
 -------------
170 166
 
171 167
 	Comments cannot be used as token concatenators, for example,
172  
-	<code>abc/**/def</code> is two tokens, $(D abc) and $(D def),
  168
+	$(D abc/**/def) is two tokens, $(D abc) and $(D def),
173 169
 	not one $(D abcdef) token.
174 170
 
175  
-<h3>Tokens</h3>
  171
+$(H3 Tokens)
176 172
 
177 173
 $(GRAMMAR
178 174
 $(GNAME Token):
@@ -182,72 +178,72 @@ $(GNAME Token):
182 178
     $(GLINK IntegerLiteral)
183 179
     $(GLINK FloatLiteral)
184 180
     $(GLINK Keyword)
185  
-    $(B /)
186  
-    $(B /=)
187  
-    $(B .)
188  
-    $(B ..)
189  
-    $(B ...)
190  
-    $(B &)
191  
-    $(B &=)
192  
-    $(B &&)
193  
-    $(B |)
194  
-    $(B |=)
195  
-    $(B ||)
196  
-    $(B -)
197  
-    $(B -=)
198  
-    $(B --)
199  
-    $(B +)
200  
-    $(B +=)
201  
-    $(B ++)
202  
-    $(B &lt;)
203  
-    $(B &lt;=)
204  
-    $(B &lt;&lt;)
205  
-    $(B &lt;&lt;=)
206  
-    $(B &lt;&gt;)
207  
-    $(B &lt;&gt;=)
208  
-    $(B &gt;)
209  
-    $(B &gt;=)
210  
-    $(B &gt;&gt;=)
211  
-    $(B &gt;&gt;&gt;=)
212  
-    $(B &gt;&gt;)
213  
-    $(B &gt;&gt;&gt;)
214  
-    $(B !)
215  
-    $(B !=)
216  
-    $(B !&lt;&gt;)
217  
-    $(B !&lt;&gt;=)
218  
-    $(B !&lt;)
219  
-    $(B !&lt;=)
220  
-    $(B !&gt;)
221  
-    $(B !&gt;=)
222  
-    $(B $(LPAREN))
223  
-    $(B $(RPAREN))
224  
-    $(B [)
225  
-    $(B ])
226  
-    $(B {)
227  
-    $(B })
228  
-    $(B ?)
229  
-    $(B ,)
230  
-    $(B ;)
231  
-    $(B :)
232  
-    $(B $)
233  
-    $(B =)
234  
-    $(B ==)
235  
-    $(B *)
236  
-    $(B *=)
237  
-    $(B %)
238  
-    $(B %=)
239  
-    $(B ^)
240  
-    $(B ^=)
241  
-    $(V2 $(B ^^))
242  
-    $(V2 $(B ^^=))
243  
-    $(B ~)
244  
-    $(B ~=)
245  
-    $(V2 $(B @))
246  
-    $(V2 $(B =>))
247  
-    $(V2 $(B #))
  181
+    $(D /)
  182
+    $(D /=)
  183
+    $(D .)
  184
+    $(D ..)
  185
+    $(D ...)
  186
+    $(CODE_ET)
  187
+    $(CODE_ET)$(D =)
  188
+    $(CODE_ET)$(CODE_ET)
  189
+    $(D |)
  190
+    $(D |=)
  191
+    $(D ||)
  192
+    $(D -)
  193
+    $(D -=)
  194
+    $(D --)
  195
+    $(D +)
  196
+    $(D +=)
  197
+    $(D ++)
  198
+    $(D $(LT))
  199
+    $(D $(LT)=)
  200
+    $(D $(LT)$(LT))
  201
+    $(D $(LT)$(LT)=)
  202
+    $(D $(LT)$(GT))
  203
+    $(D $(LT)$(GT)=)
  204
+    $(D $(GT))
  205
+    $(D $(GT)=)
  206
+    $(D $(GT)$(GT)=)
  207
+    $(D $(GT)$(GT)$(GT)=)
  208
+    $(D $(GT)$(GT))
  209
+    $(D $(GT)$(GT)$(GT))
  210
+    $(D !)
  211
+    $(D !=)
  212
+    $(D !$(LT)$(GT))
  213
+    $(D !$(LT)$(GT)=)
  214
+    $(D !$(LT))
  215
+    $(D !$(LT)=)
  216
+    $(D !$(GT))
  217
+    $(D !$(GT)=)
  218
+    $(D $(LPAREN))
  219
+    $(D $(RPAREN))
  220
+    $(D [)
  221
+    $(D ])
  222
+    $(CODE_LCURL)
  223
+    $(CODE_RCURL)
  224
+    $(D ?)
  225
+    $(D ,)
  226
+    $(D ;)
  227
+    $(D :)
  228
+    $(D $)
  229
+    $(D =)
  230
+    $(D ==)
  231
+    $(D *)
  232
+    $(D *=)
  233
+    $(CODE_PERCENT)
  234
+    $(CODE_PERCENT)$(D =)
  235
+    $(D ^)
  236
+    $(D ^=)
  237
+    $(V2 $(D ^^))
  238
+    $(V2 $(D ^^=))
  239
+    $(D ~)
  240
+    $(D ~=)
  241
+    $(V2 $(D @))
  242
+    $(V2 $(D =$(GT)))
  243
+    $(V2 $(D #))
248 244
 )
249 245
 
250  
-<h3>Identifiers</h3>
  246
+$(H3 Identifiers)
251 247
 
252 248
 $(GRAMMAR
253 249
 $(GNAME Identifier):
@@ -259,7 +255,7 @@ $(GNAME IdentifierChars):
259 255
     $(GLINK IdentifierChar) $(I IdentifierChars)
260 256
 
261 257
 $(GNAME IdentifierStart):
262  
-    $(B _)
  258
+    $(D _)
263 259
     $(I Letter)
264 260
     $(I UniversalAlpha)
265 261
 
@@ -270,15 +266,15 @@ $(GNAME IdentifierChar):
270 266
 )
271 267
 
272 268
 
273  
-	Identifiers start with a letter, $(B _), or universal alpha,
  269
+	Identifiers start with a letter, $(D _), or universal alpha,
274 270
 	and are followed by any number
275  
-	of letters, $(B _), digits, or universal alphas.
  271
+	of letters, $(D _), digits, or universal alphas.
276 272
 	Universal alphas are as defined in ISO/IEC 9899:1999(E) Appendix D.
277 273
 	(This is the C99 Standard.)
278 274
 	Identifiers can be arbitrarily long, and are case sensitive.
279  
-	Identifiers starting with $(B __) (two underscores) are reserved.
  275
+	Identifiers starting with $(D __) (two underscores) are reserved.
280 276
 
281  
-<h3>String Literals</h3>
  277
+$(H3 String Literals)
282 278
 
283 279
 $(GRAMMAR
284 280
 $(GNAME StringLiteral):
@@ -288,8 +284,7 @@ $(GNAME StringLiteral):
288 284
 $(V1
289 285
     $(GLINK EscapeSequence))
290 286
     $(GLINK HexString)
291  
-$(V2
292  
-    $(GLINK DelimitedString)
  287
+    $(V2 $(GLINK DelimitedString)
293 288
     $(GLINK TokenString))
294 289
 
295 290
 $(GNAME WysiwygString):
@@ -319,28 +314,28 @@ $(GNAME DoubleQuotedCharacter):
319 314
     $(GLINK EndOfLine)
320 315
 
321 316
 $(GNAME EscapeSequence):
322  
-    $(B \')
323  
-    $(B \")
324  
-    $(B \?)
325  
-    $(B \\)
326  
-    $(B \a)
327  
-    $(B \b)
328  
-    $(B \f)
329  
-    $(B \n)
330  
-    $(B \r)
331  
-    $(B \t)
332  
-    $(B \v)
333  
-    $(B \) $(GLINK EndOfFile)
334  
-    $(B \x) $(GLINK HexDigit) $(GLINK HexDigit)
335  
-    $(B \) $(GLINK OctalDigit)
336  
-    $(B \) $(GLINK OctalDigit) $(GLINK OctalDigit)
337  
-    $(B \) $(GLINK OctalDigit) $(GLINK OctalDigit) $(GLINK OctalDigit)
338  
-    $(B \u) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit)
339  
-    $(B \U) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit)
340  
-    $(B \) $(GLINK2 entity, NamedCharacterEntity)
  317
+    $(D \')
  318
+    $(D \")
  319
+    $(D \?)
  320
+    $(D \\)
  321
+    $(D \a)
  322
+    $(D \b)
  323
+    $(D \f)
  324
+    $(D \n)
  325
+    $(D \r)
  326
+    $(D \t)
  327
+    $(D \v)
  328
+    $(D \) $(GLINK EndOfFile)
  329
+    $(D \x) $(GLINK HexDigit) $(GLINK HexDigit)
  330
+    $(D \) $(GLINK OctalDigit)
  331
+    $(D \) $(GLINK OctalDigit) $(GLINK OctalDigit)
  332
+    $(D \) $(GLINK OctalDigit) $(GLINK OctalDigit) $(GLINK OctalDigit)
  333
+    $(D \u) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit)
  334
+    $(D \U) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit) $(GLINK HexDigit)
  335
+    $(D \) $(GLINK2 entity, NamedCharacterEntity)
341 336
 
342 337
 $(GNAME HexString):
343  
-    $(B x") $(GLINK HexStringChars) $(B ") $(GLINK StringPostfix)<sub>opt</sub>
  338
+    $(D x") $(GLINK HexStringChars) $(D ") $(GLINK StringPostfix)<sub>opt</sub>
344 339
 
345 340
 $(GNAME HexStringChars):
346 341
     $(GLINK HexStringChar)
@@ -361,7 +356,7 @@ $(GNAME DelimitedString):
361 356
     $(B q") $(I Delimiter) $(GLINK WysiwygCharacters) $(I MatchingDelimiter) $(B ")
362 357
 
363 358
 $(GNAME TokenString):
364  
-    $(B q{) $(GLINK Token)s $(B })
  359
+    $(D q)$(CODE_LCURL) $(GLINK Token)s $(CODE_RCURL)
365 360
 )
366 361
 )
367 362
 
@@ -373,9 +368,9 @@ $(GNAME TokenString):
373 368
 	)
374 369
 
375 370
 	$(P In all string literal forms, an $(GLINK EndOfLine) is regarded as a single
376  
-	\n character.)
  371
+	$(D \n) character.)
377 372
 
378  
-<h4>Wysiwyg Strings</h4>
  373
+$(H4 Wysiwyg Strings)
379 374
 
380 375
 	$(P
381 376
 	Wysiwyg "what you see is what you get" quoted strings are enclosed by r" and ".
@@ -406,10 +401,10 @@ r"ab\n" // string is 4 characters,
406 401
         // 'a', 'b', '\', 'n'
407 402
 ---------------
408 403
 
409  
-<h4>Double Quoted Strings</h4>
  404
+$(H4 Double Quoted Strings)
410 405
 
411  
-	Double quoted strings are enclosed by "". Escape sequences can be
412  
-	embedded into them with the typical \ notation.
  406
+	$(P Double quoted strings are enclosed by "". Escape sequences can be
  407
+	embedded into them with the typical $(D \) notation.)
413 408
 
414 409
 ---------------
415 410
 "hello"
@@ -422,34 +417,34 @@ r"ab\n" // string is 4 characters,
422 417
 ---------------
423 418
 
424 419
 $(V1
425  
-<h4>Escape Strings</h4>
  420
+$(H4 Escape Strings)
426 421
 
427 422
 	$(P Escape strings start with a \ and form an escape character sequence.
428 423
 	Adjacent escape strings are concatenated:
429 424
 	)
430 425
 
431 426
 $(TABLE1
432  
-$(TROW \n,			the linefeed character)
433  
-$(TROW \t,			the tab character)
434  
-$(TROW \",			the double quote character)
435  
-$(TROW \012,			octal)
436  
-$(TROW \x1A,			hex)
437  
-$(TROW \u1234,			wchar character)
438  
-$(TROW \U00101234,		dchar character)
439  
-$(TROW \&amp;reg;,		&reg; dchar character)
440  
-$(TROW \r\n,			carriage return, line feed)
  427
+$(TROW $(D \n),			the linefeed character)
  428
+$(TROW $(D \t),			the tab character)
  429
+$(TROW $(D \"),			the double quote character)
  430
+$(TROW $(D \012),			octal)
  431
+$(TROW $(D \x1A),			hex)
  432
+$(TROW $(D \u1234),			wchar character)
  433
+$(TROW $(D \U00101234),		dchar character)
  434
+$(TROW $(D \$(ET)reg;),		$(REG); dchar character)
  435
+$(TROW $(D \r\n),			carriage return, line feed)
441 436
 )
442 437
 
443 438
 	$(P Undefined escape sequences are errors.
444 439
 	Although string literals are defined to be composed of
445 440
 	UTF characters, the octal and hex escape sequences allow
446 441
 	the insertion of arbitrary binary data.
447  
-	\u and \U escape sequences can only be used to insert
  442
+	$(D \u) and $(D \U) escape sequences can only be used to insert
448 443
 	valid UTF characters.
449 444
 	)
450 445
 )
451 446
 
452  
-<h4>Hex Strings</h4>
  447
+$(H4 Hex Strings)
453 448
 
454 449
 	$(P Hex strings allow string literals to be created using hex data.
455 450
 	The hex data need not form valid UTF characters.
@@ -521,7 +516,7 @@ $(V2
521 516
 	cannot always be detected, but cause undefined behavior.)
522 517
 
523 518
 $(V2
524  
-<h4>Delimited Strings</h4>
  519
+$(H4 Delimited Strings)
525 520
 
526 521
 	$(P Delimited strings use various forms of delimiters.
527 522
 	The delimiter, whether a character or identifer,
@@ -534,10 +529,10 @@ $(V2
534 529
 
535 530
 	$(TABLE2 Nesting Delimiters,
536 531
 	$(THEAD Delimiter, Matching Delimiter)
537  
-	$(TROW [, ])
  532
+	$(TROW $(D [), $(D ]))
538 533
 	$(TROW $(LPAREN), $(RPAREN))
539  
-	$(TROW &lt;, &gt;)
540  
-	$(TROW {, })
  534
+	$(TROW $(D $(LT)), $(D $(GT)))
  535
+	$(TROW $(CODE_LCURL), $(CODE_RCURL))
541 536
 	)
542 537
 
543 538
 ---
@@ -572,11 +567,11 @@ q"/foo]/"          // "foo]"
572 567
 // q"/abc/def/"    // error
573 568
 ---
574 569
 
575  
-<h4>Token Strings</h4>
  570
+$(H4 Token Strings)
576 571
 
577  
-	$(P Token strings open with the characters $(B q{) and close with
578  
-	the token $(B }). In between must be valid D tokens.
579  
-	The $(B {) and $(B }) tokens nest.
  572
+	$(P Token strings open with the characters $(D q)$(CODE_LCURL) and close with
  573
+	the token $(CODE_RCURL). In between must be valid D tokens.
  574
+	The $(CODE_LCURL) and $(CODE_RCURL) tokens nest.
580 575
 	The string is formed of all the characters between the opening
581 576
 	and closing of the token string, including comments.
582 577
 	)
@@ -585,13 +580,15 @@ q"/foo]/"          // "foo]"
585 580
 q{foo}              // "foo"
586 581
 q{/*}*/ }           // "/*}*/ "
587 582
 q{ foo(q{hello}); } // " foo(q{hello}); "
588  
-q{ __TIME__ }       // " __TIME__ ", i.e. it is not replaced with the time
589  
-// q{ __EOF__ }     // error, as __EOF__ is not a token, it's end of file
  583
+q{ __TIME__ }       // " __TIME__ "
  584
+    // i.e. it is not replaced with the time
  585
+// q{ __EOF__ }     // error
  586
+    // __EOF__ is not a token, it's end of file
590 587
 ---
591 588
 
592 589
 )
593 590
 
594  
-<h3>$(LNAME2 characterliteral, Character Literals)</h3>
  591
+$(H3 $(LNAME2 characterliteral, Character Literals))
595 592
 
596 593
 $(GRAMMAR
597 594
 $(GNAME CharacterLiteral):
@@ -603,9 +600,9 @@ $(GNAME SingleQuotedCharacter):
603 600
 )
604 601
 
605 602
 	Character literals are a single character or escape sequence
606  
-	enclosed by single quotes, ' '.
  603
+	enclosed by single quotes, $(D ' ').
607 604
 
608  
-<h3>$(LNAME2 integerliteral, Integer Literals)</h3>
  605
+$(H3 $(LNAME2 integerliteral, Integer Literals))
609 606
 
610 607
 $(GRAMMAR
611 608
 $(GNAME IntegerLiteral):
@@ -679,7 +676,7 @@ $(GNAME DecimalDigit):
679 676
 
680 677
 $(GNAME DecimalDigitUS):
681 678
     $(GLINK DecimalDigit)
682  
-    $(B _)
  679
+    $(D _)
683 680
 
684 681
 $(GNAME BinaryDigitsUS):
685 682
     $(GLINK BinaryDigitUS)
@@ -691,7 +688,7 @@ $(GNAME BinaryDigit):
691 688
 
692 689
 $(GNAME BinaryDigitUS):
693 690
     $(GLINK BinaryDigit)
694  
-    $(B _)
  691
+    $(D _)
695 692
 
696 693
 $(GNAME OctalDigits):
697 694
     $(GLINK OctalDigit)
@@ -713,7 +710,7 @@ $(GNAME OctalDigit):
713 710
 
714 711
 $(GNAME OctalDigitUS):
715 712
     $(GLINK OctalDigit)
716  
-    $(B _)
  713
+    $(D _)
717 714
 
718 715
 $(GNAME HexDigits):
719 716
     $(GLINK HexDigit)
@@ -745,7 +742,7 @@ $(GNAME HexLetter):
745 742
     $(B D)
746 743
     $(B E)
747 744
     $(B F)
748  
-    $(B _)
  745
+    $(D _)
749 746
 )
750 747
 
751 748
 	$(P Integers can be specified in decimal, binary, octal, or hexadecimal.)
@@ -767,8 +764,8 @@ $(GNAME HexLetter):
767 764
 	by a $(SINGLEQUOTE 0x).
768 765
 	)
769 766
 
770  
-	$(P Integers can have embedded $(SINGLEQUOTE _) characters, which are ignored.
771  
-	The embedded $(SINGLEQUOTE _) are useful for formatting long literals, such
  767
+	$(P Integers can have embedded $(SINGLEQUOTE $(UNDERSCORE)) characters, which are ignored.
  768
+	The embedded $(SINGLEQUOTE $(UNDERSCORE)) are useful for formatting long literals, such
772 769
 	as using them as a thousands separator:
773 770
 	)
774 771
 
@@ -785,42 +782,37 @@ $(GNAME HexLetter):
785 782
 	$(P The type of the integer is resolved as follows:)
786 783
 
787 784
 	$(TABLE2 Decimal Literal Types,
788  
-
789  
-	$(THEAD Decimal Literal, Type)
790  
-	$(TROW 0 .. 2_147_483_647, int)
791  
-	$(TROW 2_147_483_648 .. 9_223_372_036_854_775_807L, long)
792  
-
793  
-	$(THEAD $(ARGS Decimal Literal, L Suffix), Type)
794  
-	$(TROW 0L .. 9_223_372_036_854_775_807L, long)
795  
-
796  
-	$(THEAD $(ARGS Decimal Literal, U Suffix), Type)
797  
-	$(TROW 0U .. 4_294_967_296U, uint)
798  
-	$(TROW 4_294_967_296U .. 18_446_744_073_709_551_615UL, ulong)
799  
-
800  
-	$(THEAD $(ARGS Decimal Literal, UL Suffix), Type)
801  
-	$(TROW 0UL .. 18_446_744_073_709_551_615UL, ulong)
802  
-
803  
-	$(THEAD Non-Decimal Literal, Type)
804  
-	$(TROW 0x0 .. 0x7FFF_FFFF, int)
805  
-	$(TROW 0x8000_0000 .. 0xFFFF_FFFF, uint)
806  
-	$(TROW 0x1_0000_0000 .. 0x7FFF_FFFF_FFFF_FFFF, long)
807  
-	$(TROW 0x8000_0000_0000_0000 .. 0xFFFF_FFFF_FFFF_FFFF, ulong)
808  
-
809  
-	$(THEAD $(ARGS Non-Decimal Literal, L Suffix), Type)
810  
-	$(TROW 0x0L .. 0x7FFF_FFFF_FFFF_FFFFL, long)
811  
-	$(TROW 0x8000_0000_0000_0000L .. 0xFFFF_FFFF_FFFF_FFFFL, ulong)
812  
-
813  
-	$(THEAD $(ARGS Non-Decimal Literal, U Suffix), Type)
814  
-	$(TROW 0x0U .. 0xFFFF_FFFFU, uint)
815  
-	$(TROW 0x1_0000_0000UL .. 0xFFFF_FFFF_FFFF_FFFFUL, ulong)
816  
-
817  
-	$(THEAD $(ARGS Non-Decimal Literal, UL Suffix), Type)
818  
-	$(TROW 0x0UL .. 0xFFFF_FFFF_FFFF_FFFFUL, ulong)
819  
-
  785
+	$(THEAD Literal, Type)
  786
+    $(TROW_EXPLANATORY $(I Usual decimal notation))
  787
+	$(TROW $(D 0 .. 2_147_483_647), $(D int))
  788
+	$(TROW $(D 2_147_483_648 .. 9_223_372_036_854_775_807), $(D long))
  789
+    $(MIDRULE)
  790
+    $(TROW_EXPLANATORY $(I Explicit suffixes))
  791
+	$(TROW $(D 0L .. 9_223_372_036_854_775_807L), $(D long))
  792
+	$(TROW $(D 0U .. 4_294_967_296U), $(D uint))
  793
+	$(TROW $(D 4_294_967_296U .. 18_446_744_073_709_551_615U), $(D
  794
+	ulong))
  795
+	$(TROW $(D 0UL .. 18_446_744_073_709_551_615UL), $(D ulong))
  796
+    $(MIDRULE)
  797
+    $(TROW_EXPLANATORY $(I Hexadecimal notation))
  798
+	$(TROW $(D 0x0 .. 0x7FFF_FFFF), $(D int))
  799
+	$(TROW $(D 0x8000_0000 .. 0xFFFF_FFFF), $(D uint))
  800
+	$(TROW $(D 0x1_0000_0000 .. 0x7FFF_FFFF_FFFF_FFFF), $(D long))
  801
+	$(TROW $(D 0x8000_0000_0000_0000 .. 0xFFFF_FFFF_FFFF_FFFF), $(D
  802
+	ulong))
  803
+    $(MIDRULE)
  804
+    $(TROW_EXPLANATORY $(I Hexadecimal notation with explicit suffixes))
  805
+	$(TROW $(D 0x0L .. 0x7FFF_FFFF_FFFF_FFFFL), $(D long))
  806
+	$(TROW $(D 0x8000_0000_0000_0000L .. 0xFFFF_FFFF_FFFF_FFFFL), $(D
  807
+	ulong))
  808
+	$(TROW $(D 0x0U .. 0xFFFF_FFFFU), $(D uint))
  809
+	$(TROW $(D 0x1_0000_0000U .. 0xFFFF_FFFF_FFFF_FFFFU), $(D
  810
+	ulong))
  811
+	$(TROW $(D 0x0UL .. 0xFFFF_FFFF_FFFF_FFFFUL), $(D ulong))
820 812
 	)
821 813
 
822 814
 
823  
-<h3>$(LNAME2 floatliteral, Floating Literals)</h3>
  815
+$(H3 $(LNAME2 floatliteral, Floating Literals))
824 816
 
825 817
 $(GRAMMAR
826 818
 $(GNAME FloatLiteral):
@@ -904,8 +896,8 @@ $(GNAME LeadingDecimal):
904 896
 	of 2.
905 897
 	)
906 898
 
907  
-	$(P Floating literals can have embedded $(SINGLEQUOTE _) characters, which are ignored.
908  
-	The embedded $(SINGLEQUOTE _) are useful for formatting long literals to
  899
+	$(P Floating literals can have embedded $(SINGLEQUOTE $(UNDERSCORE)) characters, which are ignored.
  900
+	The embedded $(SINGLEQUOTE $(UNDERSCORE)) are useful for formatting long literals to
909 901
 	make them more readable, such
910 902
 	as using them as a thousands separator:
911 903
 	)
@@ -951,175 +943,169 @@ $(GNAME LeadingDecimal):
951 943
 4.5 + 6.2i  // complex number (phased out)
952 944
 ---------
953 945
 
954  
-<h3>Keywords</h3>
  946
+$(H3 Keywords)
955 947
 
956 948
 	Keywords are reserved identifiers.
957 949
 
958 950
 $(GRAMMAR
959 951
 $(GNAME Keyword):
960  
-    $(B abstract)
961  
-    $(B alias)
962  
-    $(B align)
963  
-    $(B asm)
964  
-    $(B assert)
965  
-    $(B auto)
966  
-
967  
-    $(B body)
968  
-    $(B bool)
969  
-    $(B break)
970  
-    $(B byte)
971  
-
972  
-    $(B case)
973  
-    $(B cast)
974  
-    $(B catch)
975  
-    $(B cdouble)
976  
-    $(B cent)
977  
-    $(B cfloat)
978  
-    $(B char)
979  
-    $(B class)
980  
-    $(B const)
981  
-    $(B continue)
982  
-    $(B creal)
983  
-
984  
-    $(B dchar)
985  
-    $(B debug)
986  
-    $(B default)
987  
-    $(B delegate)
988  
-    $(B delete)
989  
-    $(B deprecated)
990  
-    $(B do)
991  
-    $(B double)
992  
-
993  
-    $(B else)
994  
-    $(B enum)
995  
-    $(B export)
996  
-    $(B extern)
997  
-
998  
-    $(B false)
999  
-    $(B final)
1000  
-    $(B finally)
1001  
-    $(B float)
1002  
-    $(B for)
1003  
-    $(B foreach)
1004  
-    $(B foreach_reverse)
1005  
-    $(B function)
1006  
-
1007  
-    $(B goto)
1008  
-
1009  
-    $(B idouble)
1010  
-    $(B if)
1011  
-    $(B ifloat)
1012  
-$(V2
1013  
-    $(B immutable)
1014  
-)    $(B import)
1015  
-    $(B in)
1016  
-    $(B inout)
1017  
-    $(B int)
1018  
-    $(B interface)
1019  
-    $(B invariant)
1020  
-    $(B ireal)
1021  
-    $(B is)
1022  
-
1023  
-    $(B lazy)
1024  
-    $(B long)
1025  
-
1026  
-    $(B macro)
1027  
-    $(B mixin)
1028  
-    $(B module)
1029  
-
1030  
-    $(B new)
1031  
-$(V2
1032  
-    $(B nothrow)
1033  
-)    $(B null)
1034  
-
1035  
-    $(B out)
1036  
-    $(B override)
1037  
-
1038  
-    $(B package)
1039  
-    $(B pragma)
1040  
-    $(B private)
1041  
-    $(B protected)
1042  
-    $(B public)
1043  
-$(V2
1044  
-    $(B pure)
  952
+    $(D abstract)
  953
+    $(D alias)
  954
+    $(D align)
  955
+    $(D asm)
  956
+    $(D assert)
  957
+    $(D auto)
  958
+
  959
+    $(D body)
  960
+    $(D bool)
  961
+    $(D break)
  962
+    $(D byte)
  963
+
  964
+    $(D case)
  965
+    $(D cast)
  966
+    $(D catch)
  967
+    $(D cdouble)
  968
+    $(D cent)
  969
+    $(D cfloat)
  970
+    $(D char)
  971
+    $(D class)
  972
+    $(D const)
  973
+    $(D continue)
  974
+    $(D creal)
  975
+
  976
+    $(D dchar)
  977
+    $(D debug)
  978
+    $(D default)
  979
+    $(D delegate)
  980
+    $(D delete)
  981
+    $(D deprecated)
  982
+    $(D do)
  983
+    $(D double)
  984
+
  985
+    $(D else)
  986
+    $(D enum)
  987
+    $(D export)
  988
+    $(D extern)
  989
+
  990
+    $(D false)
  991
+    $(D final)
  992
+    $(D finally)
  993
+    $(D float)
  994
+    $(D for)
  995
+    $(D foreach)
  996
+    $(D foreach_reverse)
  997
+    $(D function)
  998
+
  999
+    $(D goto)
  1000
+
  1001
+    $(D idouble)
  1002
+    $(D if)
  1003
+    $(D ifloat)
  1004
+    $(V2 $(D immutable))
  1005
+    $(D import)
  1006
+    $(D in)
  1007
+    $(D inout)
  1008
+    $(D int)
  1009
+    $(D interface)
  1010
+    $(D invariant)
  1011
+    $(D ireal)
  1012
+    $(D is)
  1013
+
  1014
+    $(D lazy)
  1015
+    $(D long)
  1016
+
  1017
+    $(D macro)
  1018
+    $(D mixin)
  1019
+    $(D module)
  1020
+
  1021
+    $(D new)
  1022
+    $(V2 $(D nothrow))
  1023
+    $(D null)
  1024
+
  1025
+    $(D out)
  1026
+    $(D override)
  1027
+
  1028
+    $(D package)
  1029
+    $(D pragma)
  1030
+    $(D private)
  1031
+    $(D protected)
  1032
+    $(D public)
  1033
+    $(V2 $(D pure))
  1034
+    $(D real)
  1035
+    $(D ref)
  1036
+    $(D return)
  1037
+
  1038
+    $(D scope)
  1039
+    $(V2 $(D shared))
  1040
+    $(D short)
  1041
+    $(D static)
  1042
+    $(D struct)
  1043
+    $(D super)
  1044
+    $(D switch)
  1045
+    $(D synchronized)
  1046
+
  1047
+    $(D template)
  1048
+    $(D this)
  1049
+    $(D throw)
  1050
+    $(D true)
  1051
+    $(D try)
  1052
+    $(D typedef)
  1053
+    $(D typeid)
  1054
+    $(D typeof)
  1055
+
  1056
+    $(D ubyte)
  1057
+    $(D ucent)
  1058
+    $(D uint)
  1059
+    $(D ulong)
  1060
+    $(D union)
  1061
+    $(D unittest)
  1062
+    $(D ushort)
  1063
+
  1064
+    $(D version)
  1065
+    $(D void)
  1066
+    $(D volatile)
  1067
+
  1068
+    $(D wchar)
  1069
+    $(D while)
  1070
+    $(D with)
  1071
+
  1072
+    $(V2 $(D __FILE__)
  1073
+    $(D __LINE__)
  1074
+    $(D __gshared)
  1075
+    $(D __traits)
  1076
+    $(D __vector)
  1077
+    $(D __parameters))
1045 1078
 )
1046  
-    $(B real)
1047  
-    $(B ref)
1048  
-    $(B return)
1049 1079
 
1050  
-    $(B scope)
1051  
-$(V2
1052  
-    $(B shared)
1053  
-)    $(B short)
1054  
-    $(B static)
1055  
-    $(B struct)
1056  
-    $(B super)
1057  
-    $(B switch)
1058  
-    $(B synchronized)
1059  
-
1060  
-    $(B template)
1061  
-    $(B this)
1062  
-    $(B throw)
1063  
-    $(B true)
1064  
-    $(B try)
1065  
-    $(B typedef)
1066  
-    $(B typeid)
1067  
-    $(B typeof)
1068  
-
1069  
-    $(B ubyte)
1070  
-    $(B ucent)
1071  
-    $(B uint)
1072  
-    $(B ulong)
1073  
-    $(B union)
1074  
-    $(B unittest)
1075  
-    $(B ushort)
1076  
-
1077  
-    $(B version)
1078  
-    $(B void)
1079  
-    $(B volatile)
1080  
-
1081  
-    $(B wchar)
1082  
-    $(B while)
1083  
-    $(B with)
1084  
-
1085  
-$(V2
1086  
-    $(B __FILE__)
1087  
-    $(B __LINE__)
1088  
-    $(B __gshared)
1089  
-    $(B __traits)
1090  
-    $(B __vector)
1091  
-    $(B __parameters))
1092  
-)
1093  
-
1094  
-<h3>$(LNAME2 specialtokens, Special Tokens)</h3>
  1080
+$(H3 $(LNAME2 specialtokens, Special Tokens))
1095 1081
 
1096 1082
 	$(P
1097 1083
 	These tokens are replaced with other tokens according to the following
1098 1084
 	table:
1099 1085
 	)
1100 1086
 
1101  
-	$(TABLE2 Special Tokens,
1102  
-	$(THEAD Special Token, Replaced with...)
  1087
+	$(TABLE_2COLS Special Tokens,
  1088
+	$(THEAD Special Token, Replaced with)
1103 1089
 $(V1
1104  
-	$(TROW $(CODE __FILE__), string literal containing source file name)
1105  
-	$(TROW $(CODE __LINE__), integer literal of the current source line number)
  1090
+	$(TROW $(D __FILE__), string literal containing source file name)
  1091
+	$(TROW $(D __LINE__), integer literal of the current source line number)
1106 1092
 )
1107  
-	$(TROW $(CODE __DATE__), string literal of the date of compilation "$(I mmm dd yyyy)")
  1093
+	$(TROW $(D __DATE__), string literal of the date of compilation "$(I mmm dd yyyy)")
1108 1094
 $(V2
1109  
-	$(TROW $(CODE __EOF__), sets the scanner to the end of the file)
  1095
+	$(TROW $(D __EOF__), sets the scanner to the end of the file)
1110 1096
 )
1111  
-	$(TROW $(CODE __TIME__), string literal of the time of compilation "$(I hh:mm:ss)")
1112  
-	$(TROW $(CODE __TIMESTAMP__), string literal of the date and time of compilation "$(I www mmm dd hh:mm:ss yyyy)")
1113  
-	$(TROW $(CODE __VENDOR__), $(ARGS Compiler vendor string, such as "Digital Mars D"))
1114  
-	$(TROW $(CODE __VERSION__), $(ARGS Compiler version as an integer, such as 2001))
  1097
+	$(TROW $(D __TIME__), string literal of the time of compilation "$(I hh:mm:ss)")
  1098
+	$(TROW $(D __TIMESTAMP__), string literal of the date and time of compilation "$(I www mmm dd hh:mm:ss yyyy)")
  1099
+	$(TROW $(D __VENDOR__), $(ARGS Compiler vendor string, such as "Digital Mars D"))
  1100
+	$(TROW $(D __VERSION__), $(ARGS Compiler version as an integer, such as 2001))
1115 1101
 	)
1116 1102
 
1117  
-<h3>$(LNAME2 Special Token Sequence, Special Token Sequences)</h3>
  1103
+$(H3 $(LNAME2 Special Token Sequence, Special Token Sequences))
1118 1104
 
1119 1105
 $(GRAMMAR
1120 1106
 $(GNAME SpecialTokenSequence):
1121  
-    $(B # line) $(GLINK IntegerLiteral) $(GLINK EndOfLine)
1122  
-    $(B # line) $(GLINK IntegerLiteral) $(GLINK Filespec) $(GLINK EndOfLine)
  1107
+    $(D # line) $(GLINK IntegerLiteral) $(GLINK EndOfLine)
  1108
+    $(D # line) $(GLINK IntegerLiteral) $(GLINK Filespec) $(GLINK EndOfLine)
1123 1109
 
1124 1110
 $(GNAME Filespec):
1125 1111
     $(B ") $(GLINK Characters) $(B ")
@@ -1159,5 +1145,3 @@ Macros:
1159 1145
 	WIKI=Lex
1160 1146
         CATEGORY_SPEC=$0
1161 1147
 
1162  
-	FULL_XREF = <a href="phobos/std_$1.html#$2">$(D std.$1.$2)</a>
1163  
-
32  posix.mak
@@ -18,8 +18,14 @@ DOC_OUTPUT_DIR=$(ROOT_DIR)/web
18 18
 GIT_HOME=git@github.com:D-Programming-Language
19 19
 
20 20
 # Latest released version
21  
-LATEST:=$(shell cd ${DMD_DIR} && git fetch --tags git@github.com:D-Programming-Language/dmd && \
22  
-git tag | grep '^v[0-9]\.[0-9]*$$' | sed 's/^v//' | sort -nr | head -n 1)
  21
+ifeq (,${LATEST})
  22
+LATEST:=$(shell cd ${DMD_DIR} && \
  23
+  git fetch --tags git@github.com:D-Programming-Language/dmd && \
  24
+  git tag | grep '^v[0-9]\.[0-9]*$$' | sed 's/^v//' | sort -nr | head -n 1)
  25