From b941baf064f7b51391e5cc2c67ca815fb1f81c85 Mon Sep 17 00:00:00 2001 From: Przemyslaw Czerpak Date: Sat, 11 Feb 2006 15:10:24 +0000 Subject: [PATCH] 2006-02-11 16:02 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl) * harbour/source/compiler/harbour.c * do not strip redundant line information when compiled for debug (-b) * harbour/source/compiler/harbour.y ! fixed typo in hb_compSequenceFinish() call - Ryszard please check me. using iNumber instead of lNumber caused that on big endian machines begin sequence / endsequence block was stripped * harbour/source/compiler/hbdead.c ! fixed stupid typo in counting length of debug variable/module names --- harbour/ChangeLog | 12 ++++++++++++ harbour/source/compiler/harbour.c | 2 +- harbour/source/compiler/harbour.y | 2 +- harbour/source/compiler/hbdead.c | 6 +++--- 4 files changed, 17 insertions(+), 5 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 2534a65974..cdff57eddb 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -8,6 +8,18 @@ 2002-12-01 13:30 UTC+0100 Foo Bar */ * fixed <-x-> match marker +2006-02-11 16:02 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl) + * harbour/source/compiler/harbour.c + * do not strip redundant line information when compiled for debug (-b) + + * harbour/source/compiler/harbour.y + ! fixed typo in hb_compSequenceFinish() call - Ryszard please check me. + using iNumber instead of lNumber caused that on big endian machines + begin sequence / endsequence block was stripped + + * harbour/source/compiler/hbdead.c + ! fixed stupid typo in counting length of debug variable/module names + 2006-02-11 13:32 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl) * harbour/include/Makefile * added missing header files diff --git a/harbour/source/compiler/harbour.c b/harbour/source/compiler/harbour.c index ee049497c1..b22c51f245 100644 --- a/harbour/source/compiler/harbour.c +++ b/harbour/source/compiler/harbour.c @@ -3722,7 +3722,7 @@ static void hb_compOptimizeJumps( void ) { LONG lOffset; - if( iPass == 2 ) + if( iPass == 2 && ! hb_comp_bDebugInfo ) hb_compStripFuncLines( hb_comp_functions.pLast ); if( hb_comp_functions.pLast->iJumps > 0 ) diff --git a/harbour/source/compiler/harbour.y b/harbour/source/compiler/harbour.y index 88ff4f4d1f..8f0c2e1253 100644 --- a/harbour/source/compiler/harbour.y +++ b/harbour/source/compiler/harbour.y @@ -1796,7 +1796,7 @@ BeginSeq : BEGINSEQ { ++hb_comp_wSeqCounter; $$ = hb_compSequenceBegi hb_compGenJumpThere( $5, hb_comp_functions.pLast->lPCodePos ); if( !$6 ) /* only if there is no RECOVER clause */ --hb_comp_wSeqCounter; /* RECOVER is also considered as end of sequence */ - hb_compSequenceFinish( $2, $4 ); + hb_compSequenceFinish( $2, $4 ); hb_comp_functions.pLast->bFlags &= ~ FUN_WITH_RETURN; } ; diff --git a/harbour/source/compiler/hbdead.c b/harbour/source/compiler/hbdead.c index 026bfcdca5..08119e72ee 100644 --- a/harbour/source/compiler/hbdead.c +++ b/harbour/source/compiler/hbdead.c @@ -167,7 +167,7 @@ static HB_CODETRACE_FUNC( hb_p_localname ) ULONG ulStart = lPCodePos; lPCodePos += 3; - while( pFunc->pCode[ lPCodePos + lPCodePos++ ] ); + while( pFunc->pCode[ lPCodePos++ ] ); hb_compCodeTraceMark( cargo, ulStart, lPCodePos - ulStart ); return hb_compCodeTraceNextPos( cargo, lPCodePos ); @@ -177,7 +177,7 @@ static HB_CODETRACE_FUNC( hb_p_modulename ) { ULONG ulStart = lPCodePos; - while( pFunc->pCode[ lPCodePos + lPCodePos++ ] ); + while( pFunc->pCode[ lPCodePos++ ] ); hb_compCodeTraceMark( cargo, ulStart, lPCodePos - ulStart ); return hb_compCodeTraceNextPos( cargo, lPCodePos ); @@ -188,7 +188,7 @@ static HB_CODETRACE_FUNC( hb_p_staticname ) ULONG ulStart = lPCodePos; lPCodePos += 4; - while( pFunc->pCode[ lPCodePos + lPCodePos++ ] ); + while( pFunc->pCode[ lPCodePos++ ] ); hb_compCodeTraceMark( cargo, ulStart, lPCodePos - ulStart ); return hb_compCodeTraceNextPos( cargo, lPCodePos );