Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Possible array bug in version 1.8.8 (*solved*)
#2
I' ve continued with more tests and definitely there is some problem with two-dimensional arrays. Look at this code:
Code:
paper 0: border 0: ink 7: bright 1: cls
DIM array(10,10) as integer

for y = 1 to 9
    for x = 1 to 9
        array(y,x) = RND*10
        print y; ","; x; " "; array(y,x)
    next x
next y

With 1.8.8 compiler and the --debug-array parameter enabled , code runs until row 2 column 9, no matter what kind of array is defined (BYTE, INTEGER, ULONG, STRING... all of them)
[Image: Capture.jpg]

... BUT if the line "print y; ","; x; " "; array(y,x)" is removed, the code runs well, without errors. I can tell more examples but basically, errors appears only when accessing array data, and never when creating the array or filling it with data.
@Boriel, hope it helps. Cheers.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)