On Thursday, 1 March 2018 at 17:48:02 UTC, Simen Kjærås wrote:
On Thursday, 1 March 2018 at 16:46:30 UTC, Yuxuan Shui wrote:
[...]
string TemplateStringOf(T...)()
if (T.length == 1)
{
import std.traits : TemplateOf, TemplateArgsOf;
import std.meta : AliasSeq, staticMap;
import
On Thursday, 1 March 2018 at 16:46:30 UTC, Yuxuan Shui wrote:
Did you actually try that? With dmd 2.079-rc1, this:
template A(T...) {}
struct B {}
struct D {}
struct E {}
template C(T...) {}
pragma(msg, (A!(B, C!(D, E))).stringof);
Prints:
A!(B, __T1CTS2ax1DTSQh1EZ)
When compiled
Yep,
On Thursday, 1 March 2018 at 16:46:30 UTC, Yuxuan Shui wrote:
On Wednesday, 28 February 2018 at 15:49:25 UTC, aliak wrote:
On Wednesday, 28 February 2018 at 15:09:56 UTC, Yuxuan Shui
wrote:
For a template instantiation expression like A!(B, C!(D, E)),
I want to get a string "A!(B, C!(D, E))",
On Thursday, 1 March 2018 at 16:46:30 UTC, Yuxuan Shui wrote:
On Wednesday, 28 February 2018 at 15:49:25 UTC, aliak wrote:
On Wednesday, 28 February 2018 at 15:09:56 UTC, Yuxuan Shui
wrote:
For a template instantiation expression like A!(B, C!(D, E)),
I want to get a string "A!(B, C!(D, E))",
On Wednesday, 28 February 2018 at 15:49:25 UTC, aliak wrote:
On Wednesday, 28 February 2018 at 15:09:56 UTC, Yuxuan Shui
wrote:
For a template instantiation expression like A!(B, C!(D, E)),
I want to get a string "A!(B, C!(D, E))", better if A, B, C,
D, E is replaced by fully qualified name.
On Wednesday, 28 February 2018 at 15:09:56 UTC, Yuxuan Shui wrote:
For a template instantiation expression like A!(B, C!(D, E)), I
want to get a string "A!(B, C!(D, E))", better if A, B, C, D, E
is replaced by fully qualified name.
Is this possible?
A!(B, C!(D, E)).stringof I guess. Will
For a template instantiation expression like A!(B, C!(D, E)), I
want to get a string "A!(B, C!(D, E))", better if A, B, C, D, E
is replaced by fully qualified name.
Is this possible?