no size yet for forward reference for nested structures

Steven Schveighoffer via Digitalmars-d digitalmars-d at puremagic.com
Fri Jan 16 10:24:22 PST 2015


On 1/16/15 2:18 AM, zeljkog wrote:
> On 16.01.15 08:04, zeljkog wrote:
>> On 15.01.15 23:30, Steven Schveighoffer wrote:
>>> On 1/15/15 9:56 AM, zeljkog wrote:
>>>> This compiles:
>>>>
>>>> import std.container;
>>>>
>>>> class Node
>>>> {
>>>>     DList!Node children;
>>>> }
>>>>
>>>
>>> Then use DList?
>>>
>>> DList is not SList, they were written by different people.
>>>
>>> -Steve
>>
>> SList.Range has moveFront, DList.Range does not.
>>
>> If I comment out SList.Range.moveFront, it compiles with SList.
>
> And yes, looks like hasAliasing!Node (from std.algorithm.move) is only
> problem.

I think this is likely the issue. std.algorithm.move should not have to 
care what is inside a class to move a reference to it.

I will file a bug. Thanks for digging into this.

-Steve


More information about the Digitalmars-d mailing list