[Issue 22210] std.meta.allSatisfy in mutual recursion classes cannot be compiled
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Oct 27 04:27:53 UTC 2021
https://issues.dlang.org/show_bug.cgi?id=22210
--- Comment #1 from Tomoya Tanjo <ttanjo at gmail.com> ---
I found that it works if I changed the order of declaration to B, C and A as
follows.
Therefore the source of this issue is issue 20443, I guess.
```dlang:sample.d
import std.meta : allSatisfy;
enum isHashable(T) = __traits(compiles,
() { T.init; }
);
class B
{
static if (isHashable!C) {}
}
class C
{
static if (allSatisfy!(isHashable, int, B)) {}
}
class A
{
static if (isHashable!B) {}
}
void main() {}
```
--
More information about the Digitalmars-d-bugs
mailing list