Properties -- another one that gets me

downs default_357-line at yahoo.de
Wed Jul 29 13:14:57 PDT 2009


Bill Baxter wrote:
> On Wed, Jul 29, 2009 at 8:11 AM, downs<default_357-line at yahoo.de> wrote:
>> Bill Baxter wrote:
>>> Just remembered this other real example of a D property that caused me
>>> discomfort:
>>>
>>>   .transform
>>>
>>> I wanted it to be an unambiguous property that returns the transform
>>> of an object, but it's too easy to misinterpret as an action that
>>> transforms the object if it can be called as
>>>
>>>    .transform().
>>>
>>> --bb
>> .transformed :)
> 
> It returns the affine transform itself, not a transformed object.
> 
> --bb

Oops. Not sure what I was thinking there.



More information about the Digitalmars-d mailing list