alias this : cast turns into endless loop

Namespace rswhite4 at googlemail.com
Sat Apr 28 15:47:56 PDT 2012


Trying with
	U opCast(U : Object)() {
		return new U();
	}

work fine. It isn't a solution, but i don't understand why this 
works and the following not:

	U opCast(U : Object)() {
		return cast(U) this._obj;
	}

I hope really some of you can explain that to me and help me to 
fix it.
And forgive me the old senseless thread title. ;)


More information about the Digitalmars-d-learn mailing list