Re: Understand signature of opOpAssign in std/complex.d

2019-11-11 Thread Adam D. Ruppe via Digitalmars-d-learn
On Monday, 11 November 2019 at 16:59:57 UTC, Q. Schroll wrote: What's the difference of is(C R == Complex!R) to is(C == Complex!R, R) then? Nothing, they do the same thing. (I'm of the opinion that the first one should actually be illegal - I thought it was until I checked for this

Re: Understand signature of opOpAssign in std/complex.d

2019-11-11 Thread Q. Schroll via Digitalmars-d-learn
On Saturday, 9 November 2019 at 13:26:12 UTC, Adam D. Ruppe wrote: On Saturday, 9 November 2019 at 12:30:46 UTC, René Heldmaier wrote: The part i don't understand is "is(C R == Complex!R)". What does that mean? That's checking the if the template argument C is a case of Complex!R, while at

Re: Understand signature of opOpAssign in std/complex.d

2019-11-09 Thread René Heldmaier via Digitalmars-d-learn
On Saturday, 9 November 2019 at 13:26:12 UTC, Adam D. Ruppe wrote: That's checking the if the template argument C is a case of Complex!R, while at the same time declaring a symbol R to hold the inner type. I got it. Thank you very much ;)

Re: Understand signature of opOpAssign in std/complex.d

2019-11-09 Thread Adam D. Ruppe via Digitalmars-d-learn
On Saturday, 9 November 2019 at 12:30:46 UTC, René Heldmaier wrote: The part i don't understand is "is(C R == Complex!R)". What does that mean? That's checking the if the template argument C is a case of Complex!R, while at the same time declaring a symbol R to hold the inner type. So