[fpc-pascal] Untyped var params

Dmitry Boyarintsev skalogryz.lists at gmail.com
Sun Jan 8 01:03:59 CET 2017

On Sat, Jan 7, 2017 at 6:53 PM, Bart <bartjunk64 at gmail.com> wrote:

> OK, I can imagine more complex examples where this may come in handy.
> And thanks for the rest of the explanation.

And only more complex examples should be used :)
There're much better ways to implement var-type variables.

I was always thinking that having untyped variables in Pascal is more a
syntactical advantage, whenever a Pascal need to target managed platforms
(i.e. Net or Java). These platforms don't any kind of pointers at all.
Thus a code written using pointers would not even compile on them.

Thus using open arrays (of bytes) and untyped variables would be a good
replacement for pointers whenever writing a cross-platform code (meaning a
code that would need to target both non-managed and managed platforms)

Not sure, but pascal JVM has its own means of dealing with pointers anyway.
My knowledge is poor on the subject of jvm, but it's well explained in the

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20170107/6547a811/attachment.html>

More information about the fpc-pascal mailing list