Weird UFC and opCall issues

Darrell via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sat Jan 3 15:20:28 PST 2015


Thanks for the feedback.

>> With classes, you need to create an instance

Need to read up classes vs struct.

This bit of syntax was very intresting.

/* Alternatively, you can move test() inside Test as a static 
opCall:

     static Test opCall()
     {
         return new Test();
     }

Then, the syntax in main could be

     ubyte [] p1 = Test().take(3).array;

*/


Very impressed with D and starting a new job. Might be able to 
use it.


More information about the Digitalmars-d-learn mailing list