February 08, 2005 Assertion failure: tocsym.c 139 - struct initialiser pointing to within | ||||
---|---|---|---|---|
| ||||
Using DMD 0.111, Windows 98SE.
----------
struct Qwert {
int[20] yuiop;
int* asdfg = yuiop.ptr;
}
----------
struct Qwert {
int[20] yuiop;
int* asdfg = &yuiop[0];
}
----------
struct Qwert {
int yuiop;
int* asdfg = &yuiop;
}
----------
Assertion failure: '!needThis()' on line 139 in file 'tocsym.c'
----------
Should this compile? The spec doesn't clarify. I guess it should go in the same compile/nocompile section as this:
----------
struct Qwert {
Qwert* asdfg = this;
}
----------
which at the moment doesn't compile.
Stewart.
--
My e-mail is valid but not my primary mailbox. Please keep replies on the 'group where everyone may benefit.
|
February 12, 2005 Re: Assertion failure: tocsym.c 139 - struct initialiser pointing to within | ||||
---|---|---|---|---|
| ||||
Posted in reply to Stewart Gordon Attachments: | Stewart Gordon wrote: | Using DMD 0.111, Windows 98SE. | | ---------- | struct Qwert { | int[20] yuiop; | int* asdfg = yuiop.ptr; | } | ---------- | struct Qwert { | int[20] yuiop; | int* asdfg = &yuiop[0]; | } | ---------- | struct Qwert { | int yuiop; | int* asdfg = &yuiop; | } | ---------- | Assertion failure: '!needThis()' on line 139 in file 'tocsym.c' | ---------- | | Should this compile? The spec doesn't clarify. I guess it should go in | the same compile/nocompile section as this: | | ---------- | struct Qwert { | Qwert* asdfg = this; | } | ---------- | | which at the moment doesn't compile. Added to DStress as http://dstress.kuehne.cn/nocompile/this_04.d http://dstress.kuehne.cn/nocompile/this_05.d http://dstress.kuehne.cn/nocompile/this_06.d Thomas |
Copyright © 1999-2021 by the D Language Foundation