see changelog

This commit is contained in:
Eddie Runia
1999-05-26 15:25:07 +00:00
parent fb35420691
commit 76f441f46d
3 changed files with 29 additions and 2 deletions

View File

@@ -1,3 +1,9 @@
19990526-16:10 Eddie Runia
* source/rtl/files.c
Pass reference error removed.
* source/rtl/extend.c
par* commands now work correctly with reference variables.
19990525-23:25 Les Griffith
* source/rtl/files.c
added logic to readstr for lasterror

View File

@@ -17,13 +17,20 @@ ULONG ulMemoryConsumed = 0;
PITEM _param( WORD wParam, WORD wMask )
{
WORD wType;
PITEM pLocal;
if( wParam <= _pcount() )
{
wType = ( stack.pBase + 1 + wParam )->wType;
if( ( wType & wMask ) || ( wType == IT_NIL && wMask == IT_ANY ) )
return stack.pBase + 1 + wParam;
{
pLocal = stack.pBase + 1 + wParam;
if( wType & IT_BYREF )
return stack.pItems + pLocal->value.wItem;
else
return pLocal;
}
else
return 0;
}
@@ -43,6 +50,8 @@ char * _parc( WORD wParam, ... )
if( wParam <= _pcount() )
{
pItem = stack.pBase + 1 + wParam;
if( pItem->wType & IT_BYREF )
pItem = stack.pItems + pItem->value.wItem;
if( IS_ARRAY( pItem ) )
{
@@ -73,6 +82,8 @@ ULONG _parclen( WORD wParam, ... )
if( wParam <= _pcount() )
{
pItem = stack.pBase + 1 + wParam;
if( pItem->wType & IT_BYREF )
pItem = stack.pItems + pItem->value.wItem;
if( IS_ARRAY( pItem ) )
{
@@ -104,6 +115,8 @@ char * _pards( WORD wParam, ... )
if( wParam <= _pcount() )
{
pItem = stack.pBase + 1 + wParam;
if( pItem->wType & IT_BYREF )
pItem = stack.pItems + pItem->value.wItem;
if( IS_ARRAY( pItem ) && wArrayIndex )
/* TODO: implement wArrayIndex use when retrieving an array element */
@@ -146,6 +159,8 @@ int _parl( WORD wParam, ... )
if( wParam <= _pcount() )
{
pItem = stack.pBase + 1 + wParam;
if( pItem->wType & IT_BYREF )
pItem = stack.pItems + pItem->value.wItem;
if( IS_ARRAY( pItem ) && wArrayIndex )
/* TODO: implement wArrayIndex use when retrieving an array element */
@@ -173,6 +188,8 @@ double _parnd( WORD wParam, ... )
if( wParam <= _pcount() )
{
pItem = stack.pBase + 1 + wParam;
if( pItem->wType & IT_BYREF )
pItem = stack.pItems + pItem->value.wItem;
if( IS_ARRAY( pItem ) && wArrayIndex )
/* TODO: implement wArrayIndex use when retrieving an array element */
@@ -206,6 +223,8 @@ int _parni( WORD wParam, ... )
if( wParam <= _pcount() )
{
pItem = stack.pBase + 1 + wParam;
if( pItem->wType & IT_BYREF )
pItem = stack.pItems + pItem->value.wItem;
if( IS_ARRAY( pItem ) && wArrayIndex )
/* TODO: implement wArrayIndex use when retrieving an array element */
@@ -239,6 +258,8 @@ long _parnl( WORD wParam, ... )
if( wParam <= _pcount() )
{
pItem = stack.pBase + 1 + wParam;
if( pItem->wType & IT_BYREF )
pItem = stack.pItems + pItem->value.wItem;
if( IS_ARRAY( pItem ) && wArrayIndex )
/* TODO: implement wArrayIndex use when retrieving an array element */

View File

@@ -450,7 +450,7 @@ HARBOUR FREAD()
if( arg1_it && arg2_it && arg3_it )
{
last_error = 0;
bytes = _fsRead(_parni(1),_parc(2),_parnl(3));
bytes = _fsRead(_parni(1),arg2_it->value.szText,_parnl(3));
last_error = errno;
}