xxxxxxxxxx
struct interp(string str) { string toString() { return str; } }
auto asInterp(string str, Args...)(interp!str first, Args rest)
{
import std.typecons : tuple;
return tuple(first, rest);
}
import std.typecons : Tuple;
void takesInterp(string str, Args...)(Tuple!(interp!str, Args) tup)
{
takesInterp(tup.expand);
}
void takesInterp(string str, Args...)(interp!str first, Args rest)
{
import std.meta : AliasSeq;
alias fullSeq = AliasSeq!(first, rest); // if you need
// impl
}
void main()
{
// istr = i"abc ${1} bcd ${3}";
auto istr = asInterp(interp!"abc "(), 1, interp!" bcd "(), 3);
takesInterp(istr);
}