From 8e1c3d04044e31839596a3f808ab32ef1d8f0aa4 Mon Sep 17 00:00:00 2001 From: Ryszard Glab Date: Tue, 24 Aug 1999 13:18:29 +0000 Subject: [PATCH] ChangeLog 19990824-14:55 --- harbour/ChangeLog | 11 +++++++++++ harbour/include/rddapi.h | 8 +++++++- harbour/source/compiler/harbour.y | 23 ++++++++++++++--------- harbour/source/hbpp/hbppint.c | 4 ++-- 4 files changed, 34 insertions(+), 12 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 2d465158ad..c57892ec26 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,14 @@ +19990824-14:55 GMT+2 Ryszard Glab + + *source/compiler/harbour.y + * corrected arguments type checking in Inc/Dec functions + + *source/hbppint.h + * memory.h is not defined in WATCOM C/C++ + + *include/rddapi.h + * added forward declaration for _AREA struct + 19990824-11:07 GMT+1 Bruno Cantero * funclist.txt include/rddapi.h diff --git a/harbour/include/rddapi.h b/harbour/include/rddapi.h index 76cd5f60d5..eb000ac0d7 100644 --- a/harbour/include/rddapi.h +++ b/harbour/include/rddapi.h @@ -115,6 +115,12 @@ typedef USHORT ERRCODE; #define APPEND_LOCK 7 #define APPEND_UNLOCK 8 +/* forward declarations + */ +struct _RDDFUNCS; +struct _AREA; + + typedef struct _FILEINFO { FHANDLE hFile; @@ -480,7 +486,7 @@ typedef FIELD * LPFIELD; * * Information to administrate the workarea */ -struct _RDDFUNCS; /* forward declaration */ + typedef struct _AREA { diff --git a/harbour/source/compiler/harbour.y b/harbour/source/compiler/harbour.y index d37d2a1d84..84e1e242c4 100644 --- a/harbour/source/compiler/harbour.y +++ b/harbour/source/compiler/harbour.y @@ -3625,11 +3625,13 @@ void Inc( void ) else debug_msg( "\n* *Inc() Compile time stack overflow\n", NULL ); - - if( pStackValType && pStackValType->cType == ' ' ) - GenWarning( _szCWarnings, 'W', WARN_NUMERIC_SUSPECT, NULL, NULL ); - else if( pStackValType->cType != 'N' ) - GenWarning( _szCWarnings, 'W', WARN_NUMERIC_TYPE, sType, NULL ); + if( pStackValType ) + { + if( pStackValType->cType == ' ' ) + GenWarning( _szCWarnings, 'W', WARN_NUMERIC_SUSPECT, NULL, NULL ); + else if( pStackValType->cType != 'N' ) + GenWarning( _szCWarnings, 'W', WARN_NUMERIC_TYPE, sType, NULL ); + } } } @@ -4372,10 +4374,13 @@ void Dec( void ) else debug_msg( "\n***Dec() Compile time stack overflow\n", NULL ); - if( pStackValType && pStackValType->cType == ' ' ) - GenWarning( _szCWarnings, 'W', WARN_NUMERIC_SUSPECT, NULL, NULL ); - else if( pStackValType->cType != 'N' ) - GenWarning( _szCWarnings, 'W', WARN_NUMERIC_TYPE, sType, NULL ); + if( pStackValType ) + { + if( pStackValType->cType == ' ' ) + GenWarning( _szCWarnings, 'W', WARN_NUMERIC_SUSPECT, NULL, NULL ); + else if( pStackValType->cType != 'N' ) + GenWarning( _szCWarnings, 'W', WARN_NUMERIC_TYPE, sType, NULL ); + } } } diff --git a/harbour/source/hbpp/hbppint.c b/harbour/source/hbpp/hbppint.c index d0a98b38f8..9b35e082f0 100644 --- a/harbour/source/hbpp/hbppint.c +++ b/harbour/source/hbpp/hbppint.c @@ -32,11 +32,11 @@ their web site at http://www.gnu.org/). */ -#if defined(__GNUC__) +#if defined(__GNUC__) || defined(__WATCOMC__) #include #include #else - #if (defined(_MSC_VER) || defined(__IBMCPP__) || defined(__WATCOMC__)) + #if ( defined(_MSC_VER) || defined(__IBMCPP__) ) #include #include #else