Currently thunk_gen uses _L_REF with
hard-coded pos for CNV_PTR_VOID.
This is a hack that doesn't work for dj64.
Needs to un-hardcode _L_REF's pos (at
least make it possible to decrement by 1,
rather than to only increment) and add a
multiplier argument.
Also if there is no reference to some other
arg, then perhaps another cvtype should
be emitted, like CNV_PTR_PVOID/__CNV_PTR_CPVOID.
I guess some syntax extension is needed,
so that instead of
DWORD ASMPASCAL INITTEXT init_DosRead(WORD fd, void *buf, UWORD count);
we write something like
DWORD ASMPASCAL INITTEXT init_DosRead(WORD fd, void _V_FW(1) *buf, UWORD count);
where "1" from _V_FW() goes to the multiplier
in _L_REF.
Currently thunk_gen uses _L_REF with hard-coded pos for CNV_PTR_VOID. This is a hack that doesn't work for dj64. Needs to un-hardcode _L_REF's pos (at least make it possible to decrement by 1, rather than to only increment) and add a multiplier argument. Also if there is no reference to some other arg, then perhaps another cvtype should be emitted, like CNV_PTR_PVOID/__CNV_PTR_CPVOID.
I guess some syntax extension is needed, so that instead of
DWORD ASMPASCAL INITTEXT init_DosRead(WORD fd, void *buf, UWORD count);
we write something likeDWORD ASMPASCAL INITTEXT init_DosRead(WORD fd, void _V_FW(1) *buf, UWORD count);
where "1" from _V_FW() goes to the multiplier in _L_REF.