Void pointers

ag0aep6g via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Tue May 17 10:25:48 PDT 2016


On 05/17/2016 05:33 PM, Alex wrote:
> But, if the slicing is made by means of iota, there is no (at least no
> explicit) dependence between the slices, which could be made by
> different objects.

How is this dependency expressed with slices?

> I'm ready to admit, that the process will work with independent
> slicing... In this case, I can omit my void* at all. So, the objects,
> which make slices, don't do this from some object, they do this just by
> calling iota. But this is little bit contra intuitive, as I imply a
> relationship between the sliced parts.

I'm not sure if I understand.

Is the object the void pointer of the slice? If so, you start the 
slicing from a null pointer, right? There is no real relationship or 
dependency between the slices then.

Or is the object some class/struct instance that creates a slice? If so, 
how does it leave a reference to itself in the slice?

> So... at the end of the day this implication exists in my head only...



More information about the Digitalmars-d-learn mailing list