Code:
TYPE KEYWORDEX ' kwdx cbName AS BYTE ' Count of bytes in keyword name bType AS BYTE ' Type of keyword szName AS ASCIIZ * 64 ' Keyword name END TYPE
using GlobalAlloc.
<256*4-bytes jump table><256*4-bytes count table><keyword count * SIZEOF(KEYWORDEX)>
LOCAL ptkwdx AS KEYWORDEX PTR
lpTbl = GlobalAlloc(%GMEM_FIXED OR %GMEM_ZEROINIT, 2048 + 2000 * SIZEOF(tkwdx))
ptkwdx = lpTbl + 2048
The errata on SWAP says that it can be used to swap the target values of pointers
and that this applies to PB/DLL 6.0 & PB/CC 2.0. However, the following produces
bad data on PB/DLL 5.0.
SWAP @ptkwd[1].szName, @ptkwd[3].szName
Just wondering if this was fixed in version 6.
------------------
Dominic Mitchell
Comment