Skip to content

Commit

Permalink
s/Halas/Alas/
Browse files Browse the repository at this point in the history
  • Loading branch information
ntrel committed Jul 29, 2012
1 parent 87b4abe commit 389e1e8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion templates_advanced.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1618,7 +1618,7 @@ \section{Templates in Templates}\label{templatesintemplates}
{ ... }
\end{dcode}
Halas, two template parameters tuples do not make sense (see \autoref{declarations}). But it's not a dead-end. First, you could try to write:
Alas, two template parameters tuples do not make sense (see \autoref{declarations}). But it's not a dead-end. First, you could try to write:
\begin{dcode}
template(AB...)
Expand Down
2 changes: 1 addition & 1 deletion templates_around.tex
Original file line number Diff line number Diff line change
Expand Up @@ -803,7 +803,7 @@ \subsection{\DD{allMembers}}
}
\end{dcode}
In the previous code, you see that among \DD{a} members, there is \DD{"object"} (the implicit \DD{object.d} module\index{module!implicit object.d module@implicit \DD{object.d} module} imported by the runtime), and \DD{"std"}, the global package that shows here whenever you import a \DD{std.*} module. It would be easy to imagine a template that recursively explore the members, find the modules and try to recurse into them to get a complete import-tree with a template. Halas \DD{"std"} blocks that, since the package itself do not have a member.\footnote{ If someone finds a way to determine with a template that \DD{b} imports \DD{std.algorithm}, I'd be delighted to see how it's done!}
In the previous code, you see that among \DD{a} members, there is \DD{"object"} (the implicit \DD{object.d} module\index{module!implicit object.d module@implicit \DD{object.d} module} imported by the runtime), and \DD{"std"}, the global package that shows here whenever you import a \DD{std.*} module. It would be easy to imagine a template that recursively explore the members, find the modules and try to recurse into them to get a complete import-tree with a template. Alas \DD{"std"} blocks that, since the package itself do not have a member.\footnote{ If someone finds a way to determine with a template that \DD{b} imports \DD{std.algorithm}, I'd be delighted to see how it's done!}
\aparte{introspection}{I'm pretty sure auto-introspection (a module calling \DD{allMembers} on its own name) used to work in Fall 2011. Now it's 2012 and this doesn't work anymore. Hmmm\ldots}
Expand Down
2 changes: 1 addition & 1 deletion templates_examples.tex
Original file line number Diff line number Diff line change
Expand Up @@ -2200,7 +2200,7 @@ \section{Statically-Checked Writeln}\label{staticallycheckedwriteln}
else static if ({ alias Checks[0] C; return C!(Args[0]);}()) // recurse
\end{dcode}
We want to apply the first checking constraint, \DD{Check[0]}, on the first argument type, \DD{Args[0]}. Halas, the D grammar does not allow the following construct:
We want to apply the first checking constraint, \DD{Check[0]}, on the first argument type, \DD{Args[0]}. Alas, the D grammar does not allow the following construct:
\begin{dcode}
else static if (Checks[0]!(Args[0])) // recurse
Expand Down

0 comments on commit 389e1e8

Please sign in to comment.