summaryrefslogtreecommitdiff
path: root/basic/source
diff options
context:
space:
mode:
Diffstat (limited to 'basic/source')
-rw-r--r--basic/source/runtime/methods.cxx16
-rw-r--r--basic/source/runtime/methods1.cxx10
-rw-r--r--basic/source/runtime/step0.cxx32
-rw-r--r--basic/source/runtime/step2.cxx14
4 files changed, 36 insertions, 36 deletions
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 1ec88fa4ef47..46cb8cd5efd4 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: methods.cxx,v $
*
- * $Revision: 1.45 $
+ * $Revision: 1.46 $
*
- * last change: $Author: ab $ $Date: 2002-10-17 14:30:00 $
+ * last change: $Author: ab $ $Date: 2002-11-18 08:36:02 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -3480,12 +3480,12 @@ RTLFUNC(LBound)
SbxDimArray* pArr = PTR_CAST(SbxDimArray,pParObj);
if( pArr )
{
- short nLower, nUpper;
+ INT32 nLower, nUpper;
short nDim = (nParCount == 3) ? (short)rPar.Get(2)->GetInteger() : 1;
- if( !pArr->GetDim( nDim, nLower, nUpper ) )
+ if( !pArr->GetDim32( nDim, nLower, nUpper ) )
StarBASIC::Error( SbERR_OUT_OF_RANGE );
else
- rPar.Get(0)->PutInteger( (INT16)nLower );
+ rPar.Get(0)->PutLong( nLower );
}
else
StarBASIC::Error( SbERR_MUST_HAVE_DIMS );
@@ -3504,12 +3504,12 @@ RTLFUNC(UBound)
SbxDimArray* pArr = PTR_CAST(SbxDimArray,pParObj);
if( pArr )
{
- short nLower, nUpper;
+ INT32 nLower, nUpper;
short nDim = (nParCount == 3) ? (short)rPar.Get(2)->GetInteger() : 1;
- if( !pArr->GetDim( nDim, nLower, nUpper ) )
+ if( !pArr->GetDim32( nDim, nLower, nUpper ) )
StarBASIC::Error( SbERR_OUT_OF_RANGE );
else
- rPar.Get(0)->PutInteger( (INT16)nUpper );
+ rPar.Get(0)->PutLong( nUpper );
}
else
StarBASIC::Error( SbERR_MUST_HAVE_DIMS );
diff --git a/basic/source/runtime/methods1.cxx b/basic/source/runtime/methods1.cxx
index 2a9df28cbdd3..56cfa8192311 100644
--- a/basic/source/runtime/methods1.cxx
+++ b/basic/source/runtime/methods1.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: methods1.cxx,v $
*
- * $Revision: 1.10 $
+ * $Revision: 1.11 $
*
- * last change: $Author: ab $ $Date: 2002-10-08 09:05:47 $
+ * last change: $Author: ab $ $Date: 2002-11-18 08:36:36 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -594,19 +594,19 @@ RTLFUNC(Array)
// Das Array ist immer vom Typ Variant
RTLFUNC(DimArray)
{
- SbxDimArray* pArray = new SbxDimArray( SbxVARIANT );
+ SbxDimArray * pArray = new SbxDimArray( SbxVARIANT );
USHORT nArrayDims = rPar.Count() - 1;
if( nArrayDims > 0 )
{
for( USHORT i = 0; i < nArrayDims ; i++ )
{
- INT16 ub = rPar.Get(i+1)->GetInteger();
+ INT32 ub = rPar.Get(i+1)->GetLong();
if( ub < 0 )
{
StarBASIC::Error( SbERR_OUT_OF_RANGE );
ub = 0;
}
- pArray->AddDim( 0, ub );
+ pArray->AddDim32( 0, ub );
}
}
// Array zurueckliefern
diff --git a/basic/source/runtime/step0.cxx b/basic/source/runtime/step0.cxx
index 8a783b919a7f..7410ef7fadd2 100644
--- a/basic/source/runtime/step0.cxx
+++ b/basic/source/runtime/step0.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: step0.cxx,v $
*
- * $Revision: 1.10 $
+ * $Revision: 1.11 $
*
- * last change: $Author: ab $ $Date: 2002-08-15 07:34:08 $
+ * last change: $Author: ab $ $Date: 2002-11-18 08:38:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -391,11 +391,11 @@ void SbiRuntime::DimImpl( SbxVariableRef refVar )
{
for( USHORT i = 1; i < pDims->Count(); )
{
- INT16 lb = pDims->Get( i++ )->GetInteger();
- INT16 ub = pDims->Get( i++ )->GetInteger();
+ INT32 lb = pDims->Get( i++ )->GetLong();
+ INT32 ub = pDims->Get( i++ )->GetLong();
if( ub < lb )
Error( SbERR_OUT_OF_RANGE ), ub = lb;
- pArray->AddDim( lb, ub );
+ pArray->AddDim32( lb, ub );
}
}
else
@@ -426,9 +426,9 @@ void SbiRuntime::StepREDIM()
// Helper function for StepREDIMP
void implCopyDimArray( SbxDimArray* pNewArray, SbxDimArray* pOldArray, short nMaxDimIndex,
- short nActualDim, short* pActualIndices, short* pLowerBounds, short* pUpperBounds )
+ short nActualDim, sal_Int32* pActualIndices, sal_Int32* pLowerBounds, sal_Int32* pUpperBounds )
{
- short& ri = pActualIndices[nActualDim];
+ sal_Int32& ri = pActualIndices[nActualDim];
for( ri = pLowerBounds[nActualDim] ; ri <= pUpperBounds[nActualDim] ; ri++ )
{
if( nActualDim < nMaxDimIndex )
@@ -438,8 +438,8 @@ void implCopyDimArray( SbxDimArray* pNewArray, SbxDimArray* pOldArray, short nMa
}
else
{
- SbxVariable* pSource = pOldArray->Get( pActualIndices );
- SbxVariable* pDest = pNewArray->Get( pActualIndices );
+ SbxVariable* pSource = pOldArray->Get32( pActualIndices );
+ SbxVariable* pDest = pNewArray->Get32( pActualIndices );
if( pSource && pDest )
*pDest = *pSource;
}
@@ -469,9 +469,9 @@ void SbiRuntime::StepREDIMP()
BOOL bRangeError = FALSE;
// Store dims to use them for copying later
- short* pLowerBounds = new short[nDims];
- short* pUpperBounds = new short[nDims];
- short* pActualIndices = new short[nDims];
+ sal_Int32* pLowerBounds = new sal_Int32[nDims];
+ sal_Int32* pUpperBounds = new sal_Int32[nDims];
+ sal_Int32* pActualIndices = new sal_Int32[nDims];
if( nDimsOld != nDimsNew )
{
bRangeError = TRUE;
@@ -481,10 +481,10 @@ void SbiRuntime::StepREDIMP()
// Compare bounds
for( short i = 1 ; i <= nDims ; i++ )
{
- short lBoundNew, uBoundNew;
- short lBoundOld, uBoundOld;
- pNewArray->GetDim( i, lBoundNew, uBoundNew );
- pOldArray->GetDim( i, lBoundOld, uBoundOld );
+ sal_Int32 lBoundNew, uBoundNew;
+ sal_Int32 lBoundOld, uBoundOld;
+ pNewArray->GetDim32( i, lBoundNew, uBoundNew );
+ pOldArray->GetDim32( i, lBoundOld, uBoundOld );
/* #69094 Allow all dimensions to be changed
although Visual Basic is not able to do so.
diff --git a/basic/source/runtime/step2.cxx b/basic/source/runtime/step2.cxx
index 90e6005ea648..3554e0bb660c 100644
--- a/basic/source/runtime/step2.cxx
+++ b/basic/source/runtime/step2.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: step2.cxx,v $
*
- * $Revision: 1.6 $
+ * $Revision: 1.7 $
*
- * last change: $Author: ab $ $Date: 2002-09-30 08:54:11 $
+ * last change: $Author: ab $ $Date: 2002-11-18 08:38:47 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -838,14 +838,14 @@ void SbiRuntime::StepDCREATE( USHORT nOp1, USHORT nOp2 )
// Dimensionen auswerten
short nDims = pArray->GetDims();
- USHORT nTotalSize = 0;
+ UINT32 nTotalSize = 0;
// es muss ein eindimensionales Array sein
- short nLower, nUpper, nSize;
- USHORT i;
+ INT32 nLower, nUpper, nSize;
+ UINT32 i;
for( i = 0 ; i < nDims ; i++ )
{
- pArray->GetDim( i+1, nLower, nUpper );
+ pArray->GetDim32( i+1, nLower, nUpper );
nSize = nUpper - nLower + 1;
if( i == 0 )
nTotalSize = nSize;
@@ -869,7 +869,7 @@ void SbiRuntime::StepDCREATE( USHORT nOp1, USHORT nOp2 )
pObj->SetName( aName );
// Das Objekt muss BASIC rufen koennen
pObj->SetParent( &rBasic );
- pArray->SbxArray::Put( pObj, i );
+ pArray->SbxArray::Put32( pObj, i );
}
}
}