const/invariant

Derek Parnell derek at psych.ward
Wed Dec 5 01:07:23 PST 2007


On Wed, 5 Dec 2007 07:43:14 +0000 (UTC), Denton Cockburn wrote:

> declare get() const and it'll work.
> 
> const int get { return mbr; }

Duh! </me slaps forehead>

Ummm, yeah that makes sense. 

-- 
Derek Parnell
Melbourne, Australia
skype: derek.j.parnell


More information about the Digitalmars-d-learn mailing list