[Gambas-user] ByRef and JIT
Jussi Lahtinen
jussi.lahtinen at gmail.com
Mon Jan 20 23:37:10 CET 2020
OK, thanks for the answer.
Jussi
On Tue, Jan 21, 2020 at 12:15 AM Benoît Minisini <g4mba5 at gmail.com> wrote:
> Le 20/01/2020 à 23:08, Jussi Lahtinen a écrit :
> > Is there going to be support for byfer?
> >
> > Jussi
>
> 'ByRef' in Gambas is a mix of syntactic sugar (done by the compiler) and
> stack trick (done by the interpreter).
>
> Calling Func(ByRef A, ByRef B) does that:
> - Enter function Func
> - Run the function
> - Put the value of local A et B on the stack
> - Leave the function
> - Get from stack the new values of A and B.
>
> I don't know how to do it cleanly in C at the moment. This is not the
> same thing as pointers!
>
> --
> Benoît Minisini
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gambas-basic.org/pipermail/user/attachments/20200121/62ef596f/attachment.html>
More information about the User
mailing list