2007-09-28 16:32 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbexprb.c
* respect -ks in macrovars and array item references
* harbour/source/vm/memvars.c
* do not detach array items during detaching enumerator variable
also in standard (without HB_COMPAT_XHB) build
This commit is contained in:
@@ -8,6 +8,14 @@
|
||||
2002-12-01 13:30 UTC+0100 Foo Bar <foo.bar@foobar.org>
|
||||
*/
|
||||
|
||||
2007-09-28 16:32 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
|
||||
* harbour/include/hbexprb.c
|
||||
* respect -ks in macrovars and array item references
|
||||
|
||||
* harbour/source/vm/memvars.c
|
||||
* do not detach array items during detaching enumerator variable
|
||||
also in standard (without HB_COMPAT_XHB) build
|
||||
|
||||
2007-09-28 14:08 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
|
||||
* harbour/include/hbapi.h
|
||||
* harbour/source/vm/itemapi.c
|
||||
|
||||
@@ -1319,6 +1319,20 @@ static HB_EXPR_FUNC( hb_compExprUseArrayAt )
|
||||
hb_compExprPushSendPop( pSelf->value.asList.pExprList, HB_COMP_PARAM );
|
||||
HB_GEN_FUNC1( PCode1, HB_P_PUSHOVARREF );
|
||||
}
|
||||
else if( pSelf->value.asList.pExprList->ExprType == HB_ET_ARRAYAT &&
|
||||
!pSelf->value.asList.pExprList->value.asList.reference )
|
||||
{
|
||||
pSelf->value.asList.pExprList->value.asList.reference = TRUE;
|
||||
HB_EXPR_USE( pSelf->value.asList.pExprList, HB_EA_PUSH_PCODE );
|
||||
pSelf->value.asList.pExprList->value.asList.reference = FALSE;
|
||||
}
|
||||
else if( pSelf->value.asList.pExprList->ExprType == HB_ET_MACRO &&
|
||||
pSelf->value.asList.pExprList->value.asMacro.SubType == HB_ET_MACRO_VAR )
|
||||
{
|
||||
pSelf->value.asList.pExprList->value.asMacro.SubType = HB_ET_MACRO_REFER;
|
||||
HB_EXPR_USE( pSelf->value.asList.pExprList, HB_EA_PUSH_PCODE );
|
||||
pSelf->value.asList.pExprList->value.asMacro.SubType = HB_ET_MACRO_VAR;
|
||||
}
|
||||
else
|
||||
HB_EXPR_USE( pSelf->value.asList.pExprList, HB_EA_PUSH_PCODE );
|
||||
}
|
||||
@@ -1364,12 +1378,25 @@ static HB_EXPR_FUNC( hb_compExprUseArrayAt )
|
||||
HB_EXPR_USE( pSelf->value.asList.pExprList, HB_EA_PUSH_PCODE );
|
||||
pSelf->value.asList.pExprList->ExprType = HB_ET_VARIABLE;
|
||||
}
|
||||
else if( pSelf->value.asList.pExprList->ExprType == HB_ET_SEND &&
|
||||
HB_SUPPORT_ARRSTR )
|
||||
else if( pSelf->value.asList.pExprList->ExprType == HB_ET_SEND )
|
||||
{
|
||||
hb_compExprPushSendPop( pSelf->value.asList.pExprList, HB_COMP_PARAM );
|
||||
HB_GEN_FUNC1( PCode1, HB_P_PUSHOVARREF );
|
||||
}
|
||||
else if( pSelf->value.asList.pExprList->ExprType == HB_ET_ARRAYAT &&
|
||||
!pSelf->value.asList.pExprList->value.asList.reference )
|
||||
{
|
||||
pSelf->value.asList.pExprList->value.asList.reference = TRUE;
|
||||
HB_EXPR_USE( pSelf->value.asList.pExprList, HB_EA_PUSH_PCODE );
|
||||
pSelf->value.asList.pExprList->value.asList.reference = FALSE;
|
||||
}
|
||||
else if( pSelf->value.asList.pExprList->ExprType == HB_ET_MACRO &&
|
||||
pSelf->value.asList.pExprList->value.asMacro.SubType == HB_ET_MACRO_VAR )
|
||||
{
|
||||
pSelf->value.asList.pExprList->value.asMacro.SubType = HB_ET_MACRO_REFER;
|
||||
HB_EXPR_USE( pSelf->value.asList.pExprList, HB_EA_PUSH_PCODE );
|
||||
pSelf->value.asList.pExprList->value.asMacro.SubType = HB_ET_MACRO_VAR;
|
||||
}
|
||||
else
|
||||
HB_EXPR_USE( pSelf->value.asList.pExprList, HB_EA_PUSH_PCODE );
|
||||
}
|
||||
|
||||
@@ -292,7 +292,6 @@ HB_ITEM_PTR hb_memvarDetachLocal( HB_ITEM_PTR pLocal )
|
||||
{
|
||||
if( HB_IS_MEMVAR( pLocal ) )
|
||||
break;
|
||||
#ifdef HB_COMPAT_XHB
|
||||
else if( HB_IS_ENUM( pLocal ) && !pLocal->item.asEnum.valuePtr )
|
||||
{
|
||||
PHB_ITEM pBase = HB_IS_BYREF( pLocal->item.asEnum.basePtr ) ?
|
||||
@@ -310,7 +309,6 @@ HB_ITEM_PTR hb_memvarDetachLocal( HB_ITEM_PTR pLocal )
|
||||
else if( pLocal->item.asRefer.value >= 0 &&
|
||||
pLocal->item.asRefer.offset == 0 )
|
||||
break;
|
||||
#endif
|
||||
pLocal = hb_itemUnRefOnce( pLocal );
|
||||
}
|
||||
while( HB_IS_BYREF( pLocal ) );
|
||||
|
||||
Reference in New Issue
Block a user