Pass 'this' as reference

Jan rotzooi at efs.fesnl
Wed Sep 12 15:01:36 UTC 2018


I'm using D not for that long and lately I have encountered an 
issue. I have class 'Foo' with a constructor using this signature:
`this (ref Bar original)`

In the 'Bar' class itself I want to create an instance of 'Foo' 
using 'this' as parameter. Something in the way of:
`Foo foo = new Foo(ref this);`

I couldn't find anything interesting on the internet to help me. 
Could anyone help me? Many thanks in advance!


More information about the Digitalmars-d-learn mailing list