[Issue 21891] Cannot alias every kind that can be passed via variadic templates
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue May 4 21:06:08 UTC 2021
https://issues.dlang.org/show_bug.cgi?id=21891
--- Comment #5 from Paul Backus <snarwin+bugzilla at gmail.com> ---
(In reply to Andrei Alexandrescu from comment #4)
> template classInstanceAlignment(T)
> if (is(T == class))
> {
> alias classInstanceAlignment = maxAlignment!(void*, typeof(T.tupleof));
> }
>
>
> Does that work because there's a template instantiation on the right-hand
> side?
Yes. It's the same reason that `Alias!(expr)` sometimes works when `expr`
doesn't.
--
More information about the Digitalmars-d-bugs
mailing list