[fpc-devel] Proposal: Enhanced replacement for assignment operators
klenin at gmail.com
Sat Aug 7 12:31:11 CEST 2010
On Sat, Aug 7, 2010 at 20:54, Marc Weustink <marc at dommelstein.net> wrote:
> Alexander Klenin wrote:
>> Code bloat/duplication is much more serious.
>> It is usually not just SomeReallyLongVariableNameY, but something like:
>> SomeFunctionReturningObject(param1, param2).PointArrayField[i] +=
>> Try rewriting that without "+=".
> Again, we are back at lazy typing. Somehow typing the realy long valiable
> name is not a problem, but declaring an extra variable is.
> (and with lazarus even that isn't needed)
As I already said in this thread, "lazy typing" is a fallacious argument.
The whole history of high-level programming languages may be summarized
as "lazy typing advancements".
> What is wrong with :
> MyObj := SomeFunctionReturningObject(param1, param2);
> MyObj.PointArrayField[i] := MyObj.PointArrayField[i] +
What's wrong with rewriting it in assembler?
It can be done, and it will work at first.
But as the project grows, code bloat becomes an impediment.
100 vs 200 lines of code is insignificant,
but 500000 vs 1000000 is a serious difference.
> Why are you still using pascal ?
Mostly because of Lazarus and execution speed.
Alexander S. Klenin
More information about the fpc-devel