Bernd Paysan <[EMAIL PROTECTED]> writes:
> On Thursday 02 January 2003 08:06, Robert Epprecht wrote:
>> : xt>string ( xt -- addr length ) look IF name>string THEN ;
>> ' 0= xt>string cr .s
>> <1> 0 ok
> Ah, that's because look doesn't know about mixed threading (xts obtained by '
> and given to execute are indirect threaded, xts compiled are direct
> threaded). Since there's already an intermediate step to get from the
> supposed xt to the real code address (decompile-prim), I put the necessary
> code into the C code that knows which sort of threading there is. Add the
> lines marked with ! to decompile_code in main.c:
>
> Label decompile_code(Label code)
> {
> ! #ifdef DIRECT_THREADED
> ! if((code >= (Cell)vm_prims) && (code < (Cell)(vm_prims+npriminfos)))
> ! return *(Label *)code;
> ! #endif
> #ifdef NO_DYNAMIC
> return code;
I get:
[ ... warnings skipped ... ]
./main.c: In function `decompile_code':
./main.c:695: warning: comparison between pointer and integer
./main.c:695: warning: comparison between pointer and integer
./main.c:701: parse error before `i'
./main.c:705: `p' undeclared (first use in this function)
./main.c:705: (Each undeclared identifier is reported only once
./main.c:705: for each function it appears in.)
./main.c:712: `i' undeclared (first use in this function)
./main.c: In function `loader':
./main.c:990: warning: comparison between pointer and integer
./main.c:995: warning: passing arg 4 of `relocate' makes integer from pointer without
a cast
make[1]: *** [main.o] Error 1
make[1]: Leaving directory `/usr/local/gforth-0.5.9-20021227/engine'
make: *** [engines] Error 2
Robert Epprecht
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]