[Gambas-user] Array Resize limits
martin p cristia
tercoide at ...67...
Fri Aug 21 00:58:38 CEST 2015
'thi is the actual (just what's important) code
Public MatRigEst As New Float[]
Function calcular() As Integer
Dim longo As Long, longo2 As Long
' longo = 18000 * 6 * 64000 ' = -1677934592 !!!
'correct value
longo = CLong(18000) * 6 * 64000 ' = 6912000000
MatRigEst.Resize(longo) '--> no error
Debug MatRigEst.Max ' ----> -1677934592 !!!
'test
For longo2 = 0 To longo
MatRigEst[longo2] = 1000 '---> Out of bounds on first element
Next
End Function
More information about the User
mailing list