fieldPostBlit - what is wrong with this and workarounds

Daniel Davidson nospam at spam.com
Thu Oct 31 07:03:26 PDT 2013


Given this code:

   import plus.tvm.rate_curve;
   struct T {
     RateCurve m;
   }
   struct S {
     const(T) rc;
   }

I get this error: Error: mutable method 
plus.models.dossier.__unittestL42_1.T.__fieldPostBlit is not 
callable using a const object

Is this fundamentally incorrect? I abandoned immutable in hopes 
that const would be more manageable and so far it has. But these 
types of issues still crop up and stop me in my tracks.

What are the requirements on RateCurve and T for this to work?

Thanks
Dan


More information about the Digitalmars-d-learn mailing list