[fpc-pascal] with statement using mulltiple objects

Philippe philippe at quarta.com.br
Sun Sep 14 17:24:04 CEST 2014


 

main problem seems to be using property whose name is common within
2 objects of the same "with" (or code within several "with") 

could it
be controlled by a compiler option? 

in that case compiler may return a
hint or warning or even an error depending of the choosen configuration
... 

does this turn it safe, or safer? 

Philippe 

Em 14.09.2014
12:06, Martin Schreiber escreveu: 

> On Sunday 14 September 2014
16:34:06 Marco van de Voort wrote:
> 
>> In the past I had the same
opinion about with (WITHs evilness is exaggerated) as many others, but
once I bumped my head a few times while using OO frameworks that were
either not of my design or very large, I basically stopped using it.
>

> Why does Free Pascal not invent a safe "with" similar as the "with"
of 
> MSElang? If I would be cynical I could write "because one must
wait until 
> Delphi has it?". ;-)
> 
> Martin
>
_______________________________________________
> fpc-pascal maillist -
fpc-pascal at lists.freepascal.org
>
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal [1]




Links:
------
[1]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20140914/6fa82d33/attachment.html>


More information about the fpc-pascal mailing list