From 956902780990e1c89d4aa04397dbfa1a8aef5fed Mon Sep 17 00:00:00 2001 From: Przemyslaw Czerpak Date: Mon, 12 Mar 2007 13:42:10 +0000 Subject: [PATCH] 2007-03-12 14:30 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl) * harbour/include/hbexpra.c * emulate xHarbour HB_ENUMINDEX() inside FOR EACH loop when HB_COMPAT_XHB macro is set It's only for compatibility - I strongly suggest to use :__enumIndex() which is more flexible and allow to chose the enumerator variable not only the one from last loop * harbour/include/hbexprb.c * added comment removed from hbexpra.c * harbour/source/compiler/hbmain.c ! fixed GPF which can appear when -b option is used in line numbering inside codeblocks --- harbour/source/compiler/hbmain.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/harbour/source/compiler/hbmain.c b/harbour/source/compiler/hbmain.c index 14ebe287fa..b8a3f8b50c 100644 --- a/harbour/source/compiler/hbmain.c +++ b/harbour/source/compiler/hbmain.c @@ -2362,9 +2362,8 @@ void hb_compLinePush( HB_COMP_DECL ) /* generates the pcode with the currently c if( HB_COMP_PARAM->currLine != HB_COMP_PARAM->lastLine ) { - if( HB_COMP_PARAM->lastLinePos < HB_COMP_PARAM->functions.pLast->lPCodePos && - HB_COMP_PARAM->functions.pLast->pCode[ HB_COMP_PARAM->lastLinePos ] == HB_P_LINE && - HB_COMP_PARAM->functions.pLast->lPCodePos - HB_COMP_PARAM->lastLinePos == 3 ) + if( HB_COMP_PARAM->functions.pLast->lPCodePos - HB_COMP_PARAM->lastLinePos == 3 && + HB_COMP_PARAM->functions.pLast->pCode[ HB_COMP_PARAM->lastLinePos ] == HB_P_LINE ) { HB_COMP_PARAM->functions.pLast->pCode[ HB_COMP_PARAM->lastLinePos + 1 ] = HB_LOBYTE( HB_COMP_PARAM->currLine ); HB_COMP_PARAM->functions.pLast->pCode[ HB_COMP_PARAM->lastLinePos + 2 ] = HB_HIBYTE( HB_COMP_PARAM->currLine );