Why an abstract pointer cannot be used as value in an associate array?
Timon Gehr
timon.gehr at gmx.ch
Thu Sep 29 04:47:19 PDT 2011
On 09/29/2011 01:28 PM, Trass3r wrote:
> Am 29.09.2011, 06:51 Uhr, schrieb Cheng Wei <rivercheng at gmail.com>:
>
>> extern(C) {
>> struct ab;
>> }
>>
>> ab*[int] map;
>>
>> void main() {
>> map.clear();
>> }
>>
>>
>> Cannot be compiled. Why?
>>
>> Thanks.
>
> Just use void* for opaque pointers in D.
Or an empty struct.
struct ab{}
More information about the Digitalmars-d-learn
mailing list