[REBOL] Re: External library interface
From: ptretter:charter at: 3-Jul-2003 8:53
This is very nice stuff. Now if we can determine the memory address of a
function in memory maybe we can take REBOL to another higher level and make
an ADDRESSOF function to point at a routine! stored in memory and pass it
back to external functions as a callback.
Paul
----- Original Message -----
From: "Ladislav Mecir" <[lmecir--mbox--vol--cz]>
To: <[rebol-list--rebol--com]>
Sent: Thursday, July 03, 2003 5:02 AM
Subject: [REBOL] Re: External library interface
Hi Romano,
> For any-string you need:
>
> address?: function [
> {get the address of a string}
> s [any-string!]
> ] [address] [
> parse/all s [s:]
> s: make struct! [s [string!]] reduce [s]
> address: make struct! [i [integer!]] none
> change third address third s
> address/i
> ]
it looks like my function is working here without modification:
address? #{3131} ; == 11169128
address? [lmecir--mbox--vol--cz] ; == 11154848
address? make image! none ; == 11169336
> Can we find a workaround for block (instead of string?)
?
> Ciao
> Romano
Ciao
-L