diff --git a/harbour/ChangeLog b/harbour/ChangeLog index d6d33d242a..32c3c21c9e 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,11 @@ +19990618-21:50 EDT David G. Holm + * makefile.icc + - genobj.c was moved to source/contrib + * source/compiler/harbour.y + - Added missing type overrides to OurMalloc() calls + * tests/working/scroll.prg + - Modified to use the preprocessor + 19990618-20:55 EDT David G. Holm * source/rtl/dir.c - Corrected #if test GNU C on Unix/Linux test to use && ! instead of || ! diff --git a/harbour/makefile.icc b/harbour/makefile.icc index 91ce1e2868..71143d6dc3 100644 --- a/harbour/makefile.icc +++ b/harbour/makefile.icc @@ -2,7 +2,7 @@ .SUFFIXES : .prg .c -path_c = source\compiler;source\hbpp;source\vm;source\rtl;source\rtl\gt;source\rtl\natmsg;source\tools +path_c = source\compiler;source\hbpp;source\vm;source\rtl;source\rtl\gt;source\rtl\natmsg;source\tools;source\contrib path_h = include path_l = source\compiler path_y = source\compiler @@ -190,6 +190,10 @@ $(path_obj)\stringp.obj : {$(path_prg)}\stringp.prg $(path_h)\pcode.h $(path_h icc /C+ $(c_opt) /Fo$@ /Tp$< ilib .\libs\icc\hbtools.lib -+$@,, +{source\contrib}.c{$(path_obj)}.obj: + icc /C+ $(c_opt) /Fo$@ /Tp$< + ilib .\libs\icc\hbtools.lib -+$@,, + $(path_exe)\harbour.exe : $(path_obj)\harboury.obj $(path_obj)\harbourl.obj $(path_obj)\genobj32.obj $(path_obj)\harbour.obj $(path_obj)\hbpp.obj $(path_obj)\hbppint.obj $(path_obj)\table.obj icc /C- $(c_opt) /Fe$(path_exe)\harbour.exe /Isource\compiler \ $(path_obj)\harboury.obj \ diff --git a/harbour/source/compiler/harbour.y b/harbour/source/compiler/harbour.y index 44acea4fc4..5ef1135d4b 100644 --- a/harbour/source/compiler/harbour.y +++ b/harbour/source/compiler/harbour.y @@ -2754,7 +2754,7 @@ WORD GetVarPos( PVAR pVars, char * szVarName ) /* returns the order + 1 of a var pVars->iUsed = 1; - pNewStackType = OurMalloc( sizeof( STACK_VAL_TYPE ) ); + pNewStackType = ( STACK_VAL_TYPE * )OurMalloc( sizeof( STACK_VAL_TYPE ) ); pNewStackType->cType = pVars->cType; pNewStackType->pPrev = pStackValType; @@ -3246,7 +3246,7 @@ void PushLogical( int iTrueFalse ) /* pushes a logical value on the virtual mach if( _iWarnings ) { - pNewStackType = OurMalloc( sizeof( STACK_VAL_TYPE ) ); + pNewStackType = ( STACK_VAL_TYPE * )OurMalloc( sizeof( STACK_VAL_TYPE ) ); pNewStackType->cType = 'L'; pNewStackType->pPrev = pStackValType; @@ -3262,7 +3262,7 @@ void PushNil( void ) { PSTACK_VAL_TYPE pNewStackType; - pNewStackType = OurMalloc( sizeof( STACK_VAL_TYPE ) ); + pNewStackType = ( STACK_VAL_TYPE * )OurMalloc( sizeof( STACK_VAL_TYPE ) ); pNewStackType->cType = 'U'; pNewStackType->pPrev = pStackValType; @@ -3281,7 +3281,7 @@ void PushDouble( double dNumber, BYTE bDec ) { PSTACK_VAL_TYPE pNewStackType; - pNewStackType = OurMalloc( sizeof( STACK_VAL_TYPE ) ); + pNewStackType = ( STACK_VAL_TYPE * )OurMalloc( sizeof( STACK_VAL_TYPE ) ); pNewStackType->cType = 'N'; pNewStackType->pPrev = pStackValType; @@ -3301,7 +3301,7 @@ void PushInteger( int iNumber ) { PSTACK_VAL_TYPE pNewStackType; - pNewStackType = OurMalloc( sizeof( STACK_VAL_TYPE ) ); + pNewStackType = ( STACK_VAL_TYPE * )OurMalloc( sizeof( STACK_VAL_TYPE ) ); pNewStackType->cType = 'N'; pNewStackType->pPrev = pStackValType; @@ -3327,7 +3327,7 @@ void PushLong( long lNumber ) { PSTACK_VAL_TYPE pNewStackType; - pNewStackType = OurMalloc( sizeof( STACK_VAL_TYPE ) ); + pNewStackType = ( STACK_VAL_TYPE * )OurMalloc( sizeof( STACK_VAL_TYPE ) ); pNewStackType->cType = 'N'; pNewStackType->pPrev = pStackValType; @@ -3347,7 +3347,7 @@ void PushString( char * szText ) { PSTACK_VAL_TYPE pNewStackType; - pNewStackType = OurMalloc( sizeof( STACK_VAL_TYPE ) ); + pNewStackType = ( STACK_VAL_TYPE * )OurMalloc( sizeof( STACK_VAL_TYPE ) ); pNewStackType->cType = 'C'; pNewStackType->pPrev = pStackValType; diff --git a/harbour/tests/working/scroll.prg b/harbour/tests/working/scroll.prg index 4c8362486f..62f8da551c 100644 --- a/harbour/tests/working/scroll.prg +++ b/harbour/tests/working/scroll.prg @@ -1,38 +1,22 @@ function main() - Scroll() - DevPos (MAXROW(), 0) - Qout( "If the GT API was linked in, the rest of the screen should be blank now." ) + CLS + @ MAXROW(), 0 SAY "If the GT API was linked in, the rest of the screen should be blank now." Pause() - Scroll() - DevPos (0, 0) - QQOUT("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - QOUT ("01234567890123456789012345678901") - DevPos (3, 5) - Qqout (" ") - DevPos (4, 5) - Qqout (" This is a test. ") - DevPos (5, 5) - Qqout (" This is only a test. ") - DevPos (6, 5) - Qqout (" Had this been a real ") - DevPos (7, 5) - Qqout (" emergency, you would ") - DevPos (8, 5) - Qqout (" be dead now. ") - DevPos (9, 5) - Qqout (" ") + CLS + @ 0,0 SAY "01234567890123456789012345678901" + @ 1,0 SAY "01234567890123456789012345678901" + @ 2,0 SAY "01234567890123456789012345678901" + @ 3,0 SAY "01234 78901" + @ 4,0 SAY "01234 This is a test. 78901" + @ 5,0 SAY "01234 This is only a test. 78901" + @ 6,0 SAY "01234 Had this been a real 78901" + @ 7,0 SAY "01234 emergency, you would 78901" + @ 8,0 SAY "01234 be dead now. 78901" + @ 9,0 SAY "01234 78901" + @ 10,0 SAY "01234567890123456789012345678901" + @ 11,0 SAY "01234567890123456789012345678901" + @ 12,0 SAY "01234567890123456789012345678901" Pause() Scroll (1, 1, 11, 30, -2, -5) pause()