[fpc-devel] "Blank slate" next version of FPC
Nikolai Zhubr
n-a-zhubr at yandex.ru
Wed Feb 20 12:26:20 CET 2019
Hi all,
20.02.2019 13:21, Sven Barth via fpc-devel:
[...]
> And we don't agree here. For us inline variables is one of the most
> horrid if not *the* most horrid thing Embarcadero could have done to
> Object Pascal.
Could you elaborate a bit about it?
While I'm not really sure what they have done exactly (not using latest
Delphi and probably not going to), I've somehow got very used to (and
confortable with) Java's inline declarations, especially "for (int i =
0; ....)" and similar constructs, and now I find myself doing this way
all the time, because:
1. it makes it easier to see the whole picture just looking at the loop
body, no need to scroll up; (The loop body might be just 10 lines of
code, whereas the whole containing function sometimes has 1000s)
2. it isoltates the scope of such variable(s), therefore preventing some
sorts of accidental misuse outside of e.g. the containing loop (which
still do happen to me ocasionally in Pascal).
So I'm just wondering, what is wrong with such approach that it is
considered so harmfull for Pascal? (Not talking here about possible
excessive complexity of actual implementation in compiler, and not
talking about the exact syntax chosen for that, just the idea as a whole)
Thank you,
Regards,
Nikolai
> Regards,
> Sven
>
>
>
> _______________________________________________
> fpc-devel maillist - fpc-devel at lists.freepascal.org
> http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel
More information about the fpc-devel
mailing list