[Lazarus] 'with' is evil, isn't it?

cobines cobines at gmail.com
Tue Aug 2 17:20:42 CEST 2011


Yes, it is treacherous. I try not to use it. Maybe if it only allowed
to refer to properties, functions of the "with" object, but it also
allows outer scope and you never know how the classes will change in
the future. Suddenly your code refers to entirely different data,
because someone decided to add a property to the "with" object.

Does it have any performance advantage (in the generated code)?

--
cobines




More information about the Lazarus mailing list