Hello Ralf,

On Tue, 8 Nov 2022 at 02:16, Ralf Quint <freedos...@gmail.com> wrote:

> On 11/7/2022 4:56 PM, Aitor SantamarĂ­a wrote:
>
>
> After all, if you declare a procedure to be far is because you want it to
> be called far, right?
>
> I have not tried anything like this with 16bit FPC, but in BP7 (and
> probably before that, but that's +30 years ago đŸ˜‰ ), procedural parameters
> have always been a far call. As Jerome mentioned, interface'd
> procedures/functions are far by default, as each unit has it's own code
> segment. And if you are using function/procedures within the same unit, you
> have to declare them as FAR. The FAR declaration is only a newer version of
> {$F+} compiler directive, which definitely was needed in TP3, not sure with
> which version of TP/BP this was introduced.
>

KEYB lies in a single PAS file, no units or any fancy stuff.
I am considering to modularise a bit in the future to make it more
readable, via $I, but not in units.

As for FPC, do you explicitly use it in {$MODE TP} mode to be compatible
> with TP/BP? (https://www.freepascal.org/docs-html/user/userse33.html) I
> am not sure right now (don't have an FPC with 16bit option installed
> anywhere here right now) how 16bit FPC is compatible with all those
> compiler options, I just recall that there was mentioned that a lot of the
> newer fluff that had been added to FPC in recent years (interface,
> generics, etc) won't work because of the memory/CPU restrictions imposed...
>
Yeah, as said in the other mails, I have tried using  -MTP when compiling,
which I assume to be equivalent to {$MODE TP}.
The problem mutates in a different casting problem, but is still there.
No fancy new stuff being used in KEYB, it's mostly assembler for the
resident part, and plain Pascal for parsing of the commandline and such.

Aitor
_______________________________________________
Freedos-devel mailing list
Freedos-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-devel

Reply via email to