d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.
[official-gcc.git] / gcc / testsuite / gdc.test / fail_compilation / test17451.d
blobb0cda2105a22aeff6230696b8dc365db60d8d9a7
1 /* TEST_OUTPUT:
2 ---
3 fail_compilation/test17451.d(22): Error: undefined identifier `allocator`
4 fail_compilation/test17451.d(23): Error: `false` has no effect
5 fail_compilation/test17451.d(30): Error: variable `test17451.HashMap!(ThreadSlot).HashMap.__lambda2.v` - size of type `ThreadSlot` is invalid
6 fail_compilation/test17451.d(44): Error: template instance `test17451.HashMap!(ThreadSlot)` error instantiating
7 ---
8 */
10 // https://issues.dlang.org/show_bug.cgi?id=17451
12 interface ManualEvent {}
14 interface EventDriver {
15 ManualEvent createManualEvent() ;
18 struct ArraySet(Key)
20 ~this()
22 try allocator;
23 catch (Exception e) false; // should never happen
27 struct HashMap(TValue)
29 alias Value = TValue;
30 static if ({ Value v; }) {}
33 struct Task {}
35 class Libevent2Driver : EventDriver {
36 Libevent2ManualEvent createManualEvent() {}
39 struct ThreadSlot {
40 ArraySet!Task tasks;
43 class Libevent2ManualEvent : ManualEvent {
44 HashMap!ThreadSlot m_waiters;