2010-06-22 04:35 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* include/hbhash.h
* src/common/hbhash.c
+ hash key changed from HB_ULONG to HB_SIZE.
* src/rtl/cdpapi.c
* src/compiler/hbmain.c
* Added casts to pacify long time msvc warnings.
* include/hbapi.h
! HB_IS_VALID_INDEX() macro fixed to use HB_SIZE.
* Changed hb_struRefer.offset structure member from HB_LONG to
HB_ISIZ, fixing one pending Win64 type mismatch.
The change doesn't modify HB_ITEM size.
* include/hbapicls.h
+ Added parameter name to one declaration.
This commit is contained in:
@@ -16,6 +16,24 @@
|
||||
The license applies to all entries newer than 2009-04-28.
|
||||
*/
|
||||
|
||||
2010-06-22 04:35 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* include/hbhash.h
|
||||
* src/common/hbhash.c
|
||||
+ hash key changed from HB_ULONG to HB_SIZE.
|
||||
|
||||
* src/rtl/cdpapi.c
|
||||
* src/compiler/hbmain.c
|
||||
* Added casts to pacify long time msvc warnings.
|
||||
|
||||
* include/hbapi.h
|
||||
! HB_IS_VALID_INDEX() macro fixed to use HB_SIZE.
|
||||
* Changed hb_struRefer.offset structure member from HB_LONG to
|
||||
HB_ISIZ, fixing one pending Win64 type mismatch.
|
||||
The change doesn't modify HB_ITEM size.
|
||||
|
||||
* include/hbapicls.h
|
||||
+ Added parameter name to one declaration.
|
||||
|
||||
2010-06-21 18:57 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)
|
||||
* contrib/hbqt/hbqt_hbqplaintextedit.cpp
|
||||
* contrib/hbqt/hbqt_hbqplaintextedit.h
|
||||
|
||||
@@ -354,7 +354,7 @@ struct hb_struRefer
|
||||
struct _HB_ITEM * itemPtr; /* item pointer */
|
||||
struct _HB_ITEM ** *itemsbasePtr; /* local variables */
|
||||
} BasePtr;
|
||||
HB_LONG offset; /* 0 for static variables */
|
||||
HB_ISIZ offset; /* 0 for static variables */
|
||||
HB_ISIZ value;
|
||||
};
|
||||
|
||||
@@ -537,12 +537,12 @@ extern void * hb_xRefResize( void * pMem, HB_SIZE ulSave, HB_SIZE ulSize, HB
|
||||
and only on 16bit platforms, so the below condition seems to be
|
||||
more reasonable. */
|
||||
#if UINT_MAX > USHRT_MAX
|
||||
/* NOTE: memcpy/memset can work with HB_ULONG data blocks */
|
||||
/* NOTE: memcpy/memset can work with HB_SIZE data blocks */
|
||||
#define hb_xmemcpy memcpy
|
||||
#define hb_xmemset memset
|
||||
#else
|
||||
/* NOTE: otherwise, the hb_xmemcpy and hb_xmemset functions
|
||||
will be used to copy and/or set HB_ULONG data blocks */
|
||||
will be used to copy and/or set HB_SIZE data blocks */
|
||||
extern HB_EXPORT void * hb_xmemcpy( void * pDestArg, void * pSourceArg, HB_SIZE ulLen ); /* copy more than memcpy() can */
|
||||
extern HB_EXPORT void * hb_xmemset( void * pDestArg, int iFill, HB_SIZE ulLen ); /* set more than memset() can */
|
||||
#endif
|
||||
@@ -702,7 +702,7 @@ extern HB_EXPORT void hb_retnll( HB_LONGLONG lNumber );/* returns a long long
|
||||
extern HB_EXPORT void hb_retnlllen( HB_LONGLONG lNumber, int iWidth ); /* returns a long long number, with specific width */
|
||||
#endif
|
||||
|
||||
#define HB_IS_VALID_INDEX( idx, max ) ( (idx) > 0 && ( HB_ULONG ) (idx) <= (max) )
|
||||
#define HB_IS_VALID_INDEX( idx, max ) ( (idx) > 0 && ( HB_SIZE ) (idx) <= (max) )
|
||||
|
||||
#ifdef _HB_API_MACROS_
|
||||
|
||||
|
||||
@@ -105,7 +105,7 @@ extern void hb_objDestructorCall( PHB_ITEM pObject );
|
||||
|
||||
#ifndef HB_NO_PROFILER
|
||||
/* profiler for object management */
|
||||
extern void hb_mthAddTime( HB_ULONG ); /* profiler from classes.c */
|
||||
extern void hb_mthAddTime( HB_ULONG ulClockTicks ); /* profiler from classes.c */
|
||||
#endif
|
||||
|
||||
#endif /* _HB_API_INTERNAL_ */
|
||||
|
||||
@@ -59,7 +59,7 @@ HB_EXTERN_BEGIN
|
||||
|
||||
struct HB_HASH_TABLE_;
|
||||
|
||||
#define HB_HASH_FUNC( hbfunc ) HB_ULONG hbfunc( struct HB_HASH_TABLE_ * HashPtr, const void * Value, const void * Cargo )
|
||||
#define HB_HASH_FUNC( hbfunc ) HB_SIZE hbfunc( struct HB_HASH_TABLE_ * HashPtr, const void * Value, const void * Cargo )
|
||||
typedef HB_HASH_FUNC( HB_HASH_FUNC_ );
|
||||
typedef HB_HASH_FUNC_ * HB_HASH_FUNC_PTR;
|
||||
|
||||
@@ -67,7 +67,7 @@ typedef struct HB_HASH_ITEM_
|
||||
{
|
||||
const void * ValPtr; /* value stored in the hash table */
|
||||
const void * KeyPtr;
|
||||
HB_ULONG key;
|
||||
HB_SIZE key;
|
||||
struct HB_HASH_ITEM_ *next;
|
||||
} HB_HASH_ITEM, * HB_HASH_ITEM_PTR;
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
|
||||
#include "hbhash.h"
|
||||
|
||||
static HB_HASH_ITEM_PTR hb_hashItemNew( HB_ULONG ulKey, const void * pKey, const void * pValue )
|
||||
static HB_HASH_ITEM_PTR hb_hashItemNew( HB_SIZE ulKey, const void * pKey, const void * pValue )
|
||||
{
|
||||
HB_HASH_ITEM_PTR pItem = (HB_HASH_ITEM_PTR) hb_xgrab( sizeof( HB_HASH_ITEM ) );
|
||||
|
||||
@@ -147,7 +147,7 @@ HB_HASH_TABLE_PTR hb_hashTableResize( HB_HASH_TABLE_PTR pTable, HB_SIZE ulNewSiz
|
||||
pItem = pTable->pItems[ ulSize ];
|
||||
while( pItem )
|
||||
{
|
||||
HB_ULONG ulKey;
|
||||
HB_SIZE ulKey;
|
||||
HB_HASH_ITEM_PTR pNewItem, pNext;
|
||||
|
||||
pNext = pItem->next;
|
||||
@@ -181,7 +181,7 @@ HB_HASH_TABLE_PTR hb_hashTableResize( HB_HASH_TABLE_PTR pTable, HB_SIZE ulNewSiz
|
||||
/* add a new value into th ehash table */
|
||||
HB_BOOL hb_hashTableAdd( HB_HASH_TABLE_PTR pTable, const void * pKey, const void * pValue )
|
||||
{
|
||||
HB_ULONG ulKey;
|
||||
HB_SIZE ulKey;
|
||||
HB_HASH_ITEM_PTR pItem;
|
||||
|
||||
ulKey = ( pTable->pKeyFunc )( pTable, pKey, pValue );
|
||||
@@ -206,7 +206,7 @@ HB_BOOL hb_hashTableAdd( HB_HASH_TABLE_PTR pTable, const void * pKey, const void
|
||||
*/
|
||||
const void * hb_hashTableFind( HB_HASH_TABLE_PTR pTable, const void * pKey )
|
||||
{
|
||||
HB_ULONG ulKey;
|
||||
HB_SIZE ulKey;
|
||||
HB_HASH_ITEM_PTR pItem;
|
||||
const void * pFound = NULL;
|
||||
|
||||
@@ -230,7 +230,7 @@ const void * hb_hashTableFind( HB_HASH_TABLE_PTR pTable, const void * pKey )
|
||||
*/
|
||||
HB_BOOL hb_hashTableDel( HB_HASH_TABLE_PTR pTable, const void *pKey )
|
||||
{
|
||||
HB_ULONG ulKey;
|
||||
HB_SIZE ulKey;
|
||||
HB_HASH_ITEM_PTR pItem;
|
||||
HB_HASH_ITEM_PTR pPrev = NULL;
|
||||
HB_BOOL bFound = HB_FALSE;
|
||||
|
||||
@@ -288,7 +288,7 @@ static PCOMSYMBOL hb_compSymbolAdd( HB_COMP_DECL, const char * szSymbolName, HB_
|
||||
HB_COMP_PARAM->symbols.iCount++;
|
||||
|
||||
if( pwPos )
|
||||
*pwPos = HB_COMP_PARAM->symbols.iCount -1; /* position number starts form 0 */
|
||||
*pwPos = ( HB_USHORT ) ( HB_COMP_PARAM->symbols.iCount - 1 ); /* position number starts form 0 */
|
||||
|
||||
return pSym;
|
||||
}
|
||||
@@ -1657,13 +1657,13 @@ static void hb_compOptimizeFrames( HB_COMP_DECL, PFUNCTION pFunc )
|
||||
pFunc->pCode[ 0 ] = HB_P_LARGEFRAME;
|
||||
pFunc->pCode[ 1 ] = HB_LOBYTE( iLocals );
|
||||
pFunc->pCode[ 2 ] = HB_HIBYTE( iLocals );
|
||||
pFunc->pCode[ 3 ] = ( HB_BYTE )( pFunc->wParamCount );
|
||||
pFunc->pCode[ 3 ] = ( HB_BYTE ) pFunc->wParamCount;
|
||||
iOffset = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
pFunc->pCode[ 1 ] = ( HB_BYTE )( iLocals );
|
||||
pFunc->pCode[ 2 ] = ( HB_BYTE )( pFunc->wParamCount );
|
||||
pFunc->pCode[ 1 ] = ( HB_BYTE ) iLocals;
|
||||
pFunc->pCode[ 2 ] = ( HB_BYTE ) pFunc->wParamCount;
|
||||
}
|
||||
bSkipFRAME = HB_FALSE;
|
||||
}
|
||||
@@ -1690,7 +1690,7 @@ static void hb_compOptimizeFrames( HB_COMP_DECL, PFUNCTION pFunc )
|
||||
else
|
||||
{
|
||||
if( pFunc->fVParams )
|
||||
pFunc->pCode[ 0 ] = iOffset ? HB_P_LARGEVFRAME : HB_P_VFRAME;
|
||||
pFunc->pCode[ 0 ] = ( HB_BYTE ) ( iOffset ? HB_P_LARGEVFRAME : HB_P_VFRAME );
|
||||
|
||||
if( bSkipSFRAME )
|
||||
{
|
||||
|
||||
@@ -1966,9 +1966,9 @@ static PHB_CODEPAGE hb_buildCodePage( const char * id, const char * info,
|
||||
{
|
||||
if( iAcc && nACSort != HB_CDP_ACSORT_NONE )
|
||||
++iAccUp;
|
||||
sort[ ucUp ] = ++iSortUp - iAccUp;
|
||||
sort[ ucUp ] = ( HB_UCHAR ) ( ++iSortUp - iAccUp );
|
||||
if( acc )
|
||||
acc[ ucUp ] = iSortUp;
|
||||
acc[ ucUp ] = ( HB_UCHAR ) iSortUp;
|
||||
if( ucUp2 > ucUp )
|
||||
ucUp2 = ucUp;
|
||||
}
|
||||
@@ -1989,9 +1989,9 @@ static PHB_CODEPAGE hb_buildCodePage( const char * id, const char * info,
|
||||
{
|
||||
if( iAcc && nACSort != HB_CDP_ACSORT_NONE )
|
||||
++iAccLo;
|
||||
sort[ ucLo ] = ++iSortLo - iAccLo;
|
||||
sort[ ucLo ] = ( HB_UCHAR ) ( ++iSortLo - iAccLo );
|
||||
if( acc )
|
||||
acc[ ucLo ] = iSortLo;
|
||||
acc[ ucLo ] = ( HB_UCHAR ) iSortLo;
|
||||
if( ucLo2 > ucLo )
|
||||
ucLo2 = ucLo;
|
||||
}
|
||||
@@ -2043,9 +2043,9 @@ static PHB_CODEPAGE hb_buildCodePage( const char * id, const char * info,
|
||||
else
|
||||
iAdd = iUp + iLo;
|
||||
|
||||
sort[ i ] += iAdd;
|
||||
sort[ i ] += ( HB_UCHAR ) iAdd;
|
||||
if( acc )
|
||||
acc[ i ] += iAdd;
|
||||
acc[ i ] += ( HB_UCHAR ) iAdd;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user