I just got it! (invariant/const)
Jason House
jason.james.house at gmail.com
Thu Apr 10 08:47:51 PDT 2008
Georg Wrede Wrote:
> Lionello Lunesu wrote:
> >
> > "Jason House" <jason.james.house at gmail.com> wrote in message
> > news:ftiuj8$mob$1 at digitalmars.com...
> >
> >> Georg Wrede Wrote:
> >>> Simen Kjaeraas wrote:
> >>> > On Wed, 09 Apr 2008 15:40:37 +0200, Janice Caron wrote:
> >>>
> >>> >> You know that. I know that. Why would anyone think it strange?
> >>> >
> >>> > I think it is because invMemberFunc is invariant. Many read this as
> >>> > "will not change anything", even though it is not what it means.
> >>>
> >>> I seriously think the problem is with the phrase "invMemberFunc is
> >>> invariant".
> >>>
> >>> This leads people to think invariantness is a property of the function,
> >>> instead of it merely requiring an invariant "this".
> >>>
> >>> Maybe we should figure out another way of stating it.
> >>
> >> Is that really the best solution? Why not have do what people nievely
> >> think it does? The code optimizer would benefit from that as well.
> >
> > I agree.. And one less keyword, which, it seems, is a goal in itself.
>
> I wasn't thinking of changing D,
Right, but I am ;)
> I was thinking more what we should
> *say* when we talk about invariantness and functions.
If we have to say special qualifiers every time we talk about stuff, it's a broken definition :( The less corner cases there are, the easier it'll be to discuss, the easier it'll be to learn, and the lower the potential for compiler bugs will be...
More information about the Digitalmars-d
mailing list