> Micha Nelissen said:
> > FPC will never support this, AFAIK. It doesn't really add anything new, it
> > just shortens the code somewhat. Only in toy examples is it nice,
> 
> Could you expand this answer to cover the reasons why people might use
> Pascal rather than assembly language? Your argument seems to advocate
> using the lowest level language available...

> I'm a big fan of compact code and language features that promote it.
> Give me "StringList.SaveToFile()" any day over the laborious code
> that starts "var F:TextFile;"

(
A.S.
These don't have the same properties. Using basic I/O one can work with
textfiles larger than the (virtual) memory. With stringlist there always
must be full in memory loading.
Moreover stringlists get painfully slow over a few ten thousand lines.
)

However stringlist _adds_ something. You can really do stuff in a few lines
that takes tons of manual coding.

FOR IN on the other hand saves only two lines of plain typing, something
that could even be compensated with a small Lazarus codetools "generate
construct" macro.

Moreover stringlist doesn't need compiler support to do it.
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to