2008-05-31 14:44 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbmacro.ch
* harbour/source/vm/macro.c
* harbour/source/vm/hvm.c
- removed HB_MACRO_STATEMENTS and HB_SM_PREPROC
This commit is contained in:
@@ -8,6 +8,12 @@
|
||||
2008-12-31 13:59 UTC+0100 Foo Bar <foo.bar@foobar.org>
|
||||
*/
|
||||
|
||||
2008-05-31 14:44 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
|
||||
* harbour/include/hbmacro.ch
|
||||
* harbour/source/vm/macro.c
|
||||
* harbour/source/vm/hvm.c
|
||||
- removed HB_MACRO_STATEMENTS and HB_SM_PREPROC
|
||||
|
||||
2008-05-31 13:15 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
|
||||
* contrib/hbcurl/hbcurl.c
|
||||
* contrib/hbcurl/tests/ftp_uldl.prg
|
||||
|
||||
@@ -58,7 +58,6 @@
|
||||
/* runtime settings for macro compiler */
|
||||
#define HB_SM_HARBOUR 1 /* extended Harbour features */
|
||||
#define HB_SM_XBASE 2 /* extended xbase compatibility */
|
||||
#define HB_SM_PREPROC 4 /* enable/disable commands preprocessing */
|
||||
#define HB_SM_SHORTCUTS 8 /* enable/disable sortcuts for logical operators */
|
||||
#define HB_SM_ARRSTR 16 /* enable/disable strings as array of bytes */
|
||||
#define HB_SM_RT_MACRO 64 /* disable automatic setup of macro flag */
|
||||
|
||||
@@ -90,12 +90,6 @@
|
||||
|
||||
#include "hbmemory.ch"
|
||||
|
||||
#ifdef HB_MACRO_STATEMENTS
|
||||
#include "hbpp.h"
|
||||
#endif
|
||||
|
||||
/* DEBUG only*/
|
||||
/* #include <windows.h> */
|
||||
|
||||
HB_FUNC_EXTERN( SYSINIT );
|
||||
|
||||
@@ -508,10 +502,6 @@ HB_EXPORT int hb_vmQuit( void )
|
||||
|
||||
hb_vmDoExitFunctions(); /* process defined EXIT functions */
|
||||
|
||||
#ifdef HB_MACRO_STATEMENTS
|
||||
hb_pp_Free();
|
||||
#endif
|
||||
|
||||
hb_idleShutDown();
|
||||
|
||||
/* process AtExit registered functions */
|
||||
|
||||
@@ -59,10 +59,6 @@
|
||||
#include "hbcomp.h"
|
||||
#include "hbstack.h"
|
||||
|
||||
#ifdef HB_MACRO_STATEMENTS
|
||||
#include "hbpp.h"
|
||||
#endif
|
||||
|
||||
/* various flags for macro compiler */
|
||||
#ifdef HB_C52_STRICT
|
||||
static ULONG s_macroFlags = HB_SM_SHORTCUTS;
|
||||
@@ -390,10 +386,7 @@ void hb_macroGetValue( HB_ITEM_PTR pItem, BYTE iContext, BYTE flags )
|
||||
HB_MACRO struMacro;
|
||||
int iStatus;
|
||||
BOOL fFree;
|
||||
#ifdef HB_MACRO_STATEMENTS
|
||||
char * pText;
|
||||
char * pOut;
|
||||
#endif
|
||||
|
||||
struMacro.mode = HB_MODE_MACRO;
|
||||
struMacro.supported = (flags & HB_SM_RT_MACRO) ? s_macroFlags : flags;
|
||||
struMacro.Flags = HB_MACRO_GEN_PUSH;
|
||||
@@ -436,42 +429,7 @@ void hb_macroGetValue( HB_ITEM_PTR pItem, BYTE iContext, BYTE flags )
|
||||
struMacro.Flags |= HB_MACRO_GEN_PARE;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef HB_MACRO_STATEMENTS
|
||||
if( struMacro.supported & HB_SM_PREPROC )
|
||||
{
|
||||
char * ptr;
|
||||
int slen;
|
||||
|
||||
pText = ( char * ) hb_xgrab( HB_PP_STR_SIZE );
|
||||
pOut = ( char * ) hb_xgrab( HB_PP_STR_SIZE );
|
||||
ptr = pText;
|
||||
slen = HB_MIN( strlen( struMacro.string ), HB_PP_STR_SIZE - 1 );
|
||||
memcpy( pText, struMacro.string, slen );
|
||||
pText[ slen ] = 0;
|
||||
memset( pOut, 0, HB_PP_STR_SIZE );
|
||||
|
||||
HB_SKIPTABSPACES( ptr );
|
||||
|
||||
if( !hb_pp_topDefine )
|
||||
{
|
||||
hb_pp_Table();
|
||||
}
|
||||
|
||||
hb_pp_ParseExpression( ptr, pOut );
|
||||
struMacro.string = pText;
|
||||
struMacro.length = strlen( pText );
|
||||
}
|
||||
#endif
|
||||
|
||||
iStatus = hb_macroParse( &struMacro );
|
||||
#ifdef HB_MACRO_STATEMENTS
|
||||
if( struMacro.supported & HB_SM_PREPROC )
|
||||
{
|
||||
hb_xfree( pText );
|
||||
hb_xfree( pOut );
|
||||
}
|
||||
#endif
|
||||
hb_stackPop(); /* remove compiled string */
|
||||
if( iStatus == HB_MACRO_OK && ( struMacro.status & HB_MACRO_CONT ) )
|
||||
{
|
||||
@@ -968,14 +926,6 @@ HB_FUNC( HB_SETMACRO )
|
||||
hb_macroSetMacro( hb_itemGetL( pValue ), ulFlags );
|
||||
break;
|
||||
|
||||
case HB_SM_PREPROC :
|
||||
/* enable/disable preprocessing before compilation */
|
||||
hb_retl( s_macroFlags & ulFlags );
|
||||
pValue = hb_param( 2, HB_IT_LOGICAL );
|
||||
if( pValue )
|
||||
hb_macroSetMacro( hb_itemGetL( pValue ), ulFlags );
|
||||
break;
|
||||
|
||||
case HB_SM_ARRSTR :
|
||||
/* enable/disable processing of strings as an array of bytes */
|
||||
hb_retl( s_macroFlags & ulFlags );
|
||||
|
||||
Reference in New Issue
Block a user