2001-12-05 19:44 UTC+0100 Viktor Szakats <viktor.szakats@syenar.hu>

quick correction
This commit is contained in:
Viktor Szakats
2001-12-05 18:55:05 +00:00
parent 6cc5a3a4e2
commit 6f198210d1
4 changed files with 32 additions and 32 deletions

View File

@@ -5,13 +5,13 @@
* contrib/libct/ctmath.c
* Renamed math handler C level functions to match the
naming system of Harbour:
hb_getMathError -> hb_mathGetError
hb_resetMathError -> hb_mathResetError
hb_isMathHandler -> hb_mathIsHandler
hb_installMathHandler -> hb_mathHandlerInstall
hb_deinstallMathHandler -> hb_mathHandlerDeinstall
hb_setMathHandlerStatus -> hb_mathHandlerSetStatus
hb_getMathHandlerStatus -> hb_mathHandlerGetStatus
hb_getMathError -> hb_mathGetError
hb_resetMathError -> hb_mathResetError
hb_isMathHandler -> hb_mathIsHandler
hb_installMathHandler -> hb_mathInstallHandler
hb_deinstallMathHandler -> hb_mathDeinstallHandler
hb_setMathHandlerStatus -> hb_mathSetHandlerStatus
hb_getMathHandlerStatus -> hb_mathGetHandlerStatus
HB_MATHERR* -> HB_MATH_ERR*
* source/rtl/mlctopos.c

View File

@@ -66,9 +66,9 @@ int ct_math_init (void)
if (hb_mathIsHandler())
{
s_ctMathHandler = hb_mathHandlerInstall (ct_matherr);
s_ctMathHandler = hb_mathInstallHandler (ct_matherr);
/* CT3 math handler is inactive by default */
hb_mathHandlerSetStatus (s_ctMathHandler, CT_MATHERR_STATUS_INACTIVE);
hb_mathSetHandlerStatus (s_ctMathHandler, CT_MATHERR_STATUS_INACTIVE);
return (1);
}
return (0);
@@ -79,7 +79,7 @@ int ct_math_exit (void)
HB_TRACE(HB_TR_DEBUG, ("ctmath_exit()"));
if (hb_mathIsHandler())
{
hb_mathHandlerDeinstall (s_ctMathHandler);
hb_mathDeinstallHandler (s_ctMathHandler);
}
return (1);
}
@@ -104,7 +104,7 @@ void ct_matherrbegin (void)
HB_TRACE(HB_TR_DEBUG, ("ct_matherrbegin()"));
if (hb_mathIsHandler() && (s_ct_matherr_status == CT_MATHERR_STATUS_ACTIVE))
{
hb_mathHandlerSetStatus (s_ctMathHandler, CT_MATHERR_STATUS_ACTIVE);
hb_mathSetHandlerStatus (s_ctMathHandler, CT_MATHERR_STATUS_ACTIVE);
}
return;
}
@@ -114,7 +114,7 @@ void ct_matherrend (void)
HB_TRACE(HB_TR_DEBUG, ("ct_matherrend()"));
if (hb_mathIsHandler())
{
hb_mathHandlerSetStatus (s_ctMathHandler, CT_MATHERR_STATUS_INACTIVE);
hb_mathSetHandlerStatus (s_ctMathHandler, CT_MATHERR_STATUS_INACTIVE);
}
return;
}

View File

@@ -106,10 +106,10 @@ typedef PHB_MATH_HANDLERCHAINELEMENT HB_MATH_HANDLERHANDLE;
extern int hb_mathGetError( void );
extern void hb_mathResetError( void );
extern int hb_mathIsHandler( void );
extern HB_MATH_HANDLERHANDLE hb_mathHandlerInstall( HB_MATH_HANDLERPROC handlerproc );
extern int hb_mathHandlerDeinstall( HB_MATH_HANDLERHANDLE handle );
extern int hb_mathHandlerSetStatus( HB_MATH_HANDLERHANDLE handle, int status );
extern int hb_mathHandlerGetStatus( HB_MATH_HANDLERHANDLE handle );
extern HB_MATH_HANDLERHANDLE hb_mathInstallHandler( HB_MATH_HANDLERPROC handlerproc );
extern int hb_mathDeinstallHandler( HB_MATH_HANDLERHANDLE handle );
extern int hb_mathSetHandlerStatus( HB_MATH_HANDLERHANDLE handle, int status );
extern int hb_mathGetHandlerStatus( HB_MATH_HANDLERHANDLE handle );
#define HB_MATH_HANDLER_STATUS_NOTFOUND ( ( int ) -1 )
#define HB_MATH_HANDLER_STATUS_INACTIVE ( ( int ) 0 )

View File

@@ -91,11 +91,11 @@ int hb_mathIsHandler( void )
static PHB_MATH_HANDLERCHAINELEMENT s_pChain = NULL; /* TODO: make this thread safe */
/* install custom math handler */
HB_MATH_HANDLERHANDLE hb_mathHandlerInstall( HB_MATH_HANDLERPROC handlerproc )
HB_MATH_HANDLERHANDLE hb_mathInstallHandler( HB_MATH_HANDLERPROC handlerproc )
{
PHB_MATH_HANDLERCHAINELEMENT pChain, pNewChainelement;
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerInstall (%p)", handlerproc));
HB_TRACE(HB_TR_DEBUG, ("hb_mathInstallHandler (%p)", handlerproc));
pNewChainelement = (PHB_MATH_HANDLERCHAINELEMENT)hb_xgrab (sizeof (HB_MATH_HANDLERCHAINELEMENT));
pNewChainelement->handlerproc = handlerproc;
pNewChainelement->status = HB_MATH_HANDLER_STATUS_ACTIVE;
@@ -118,11 +118,11 @@ HB_MATH_HANDLERHANDLE hb_mathHandlerInstall( HB_MATH_HANDLERPROC handlerproc )
}
/* deinstall custom math handler */
int hb_mathHandlerDeinstall( HB_MATH_HANDLERHANDLE handle )
int hb_mathDeinstallHandler( HB_MATH_HANDLERHANDLE handle )
{
PHB_MATH_HANDLERCHAINELEMENT pChain;
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerDeinstall (%p)", handle));
HB_TRACE(HB_TR_DEBUG, ("hb_mathDeinstallHandler (%p)", handle));
if( handle != NULL )
{
@@ -154,11 +154,11 @@ int hb_mathHandlerDeinstall( HB_MATH_HANDLERHANDLE handle )
}
/* set custom math handler status */
int hb_mathHandlerSetStatus( HB_MATH_HANDLERHANDLE handle, int status )
int hb_mathSetHandlerStatus( HB_MATH_HANDLERHANDLE handle, int status )
{
int oldstatus = HB_MATH_HANDLER_STATUS_NOTFOUND;
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerSetStatus (%p, %i)", handle, status));
HB_TRACE(HB_TR_DEBUG, ("hb_mathSetHandlerStatus (%p, %i)", handle, status));
if( handle != NULL )
{
@@ -170,9 +170,9 @@ int hb_mathHandlerSetStatus( HB_MATH_HANDLERHANDLE handle, int status )
}
/* get custom math handler status */
int hb_mathHandlerGetStatus( HB_MATH_HANDLERHANDLE handle )
int hb_mathGetHandlerStatus( HB_MATH_HANDLERHANDLE handle )
{
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerGetStatus (%p)", handle));
HB_TRACE(HB_TR_DEBUG, ("hb_mathGetHandlerStatus (%p)", handle));
if( handle != NULL )
return ( ( PHB_MATH_HANDLERCHAINELEMENT ) handle )->status;
@@ -306,30 +306,30 @@ int hb_mathIsHandler( void )
return 0;
}
HB_MATH_HANDLERHANDLE hb_mathHandlerInstall( HB_MATH_HANDLERPROC handlerproc )
HB_MATH_HANDLERHANDLE hb_mathInstallHandler( HB_MATH_HANDLERPROC handlerproc )
{
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerInstall (%p)", handlerproc));
HB_TRACE(HB_TR_DEBUG, ("hb_mathInstallHandler (%p)", handlerproc));
return ( HB_MATH_HANDLERHANDLE ) NULL;
}
int hb_mathHandlerDeinstall( HB_MATH_HANDLERHANDLE handle )
int hb_mathDeinstallHandler( HB_MATH_HANDLERHANDLE handle )
{
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerDeinstall (%p)", handle));
HB_TRACE(HB_TR_DEBUG, ("hb_mathDeinstallHandler (%p)", handle));
return -1;
}
int hb_mathHandlerSetStatus( HB_MATH_HANDLERHANDLE handle, int status )
int hb_mathSetHandlerStatus( HB_MATH_HANDLERHANDLE handle, int status )
{
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerSetStatus (%p, %i)", handle, status));
HB_TRACE(HB_TR_DEBUG, ("hb_mathSetHandlerStatus (%p, %i)", handle, status));
return HB_MATH_HANDLER_STATUS_NOTFOUND;
}
int hb_mathHandlerGetStatus( HB_MATH_HANDLERHANDLE handle )
int hb_mathGetHandlerStatus( HB_MATH_HANDLERHANDLE handle )
{
HB_TRACE(HB_TR_DEBUG, ("hb_mathHandlerGetStatus (%p)", handle));
HB_TRACE(HB_TR_DEBUG, ("hb_mathGetHandlerStatus (%p)", handle));
return HB_MATH_HANDLER_STATUS_NOTFOUND;
}