**** Merged from MCS ****
[mono-project.git] / mcs / btests / Array3.vb
blobcb283d27e6bbcc2bf6b57e4f1561fd150018a2d2
1 ' Unhandled Exception: System.IndexOutOfRangeException: Index was outside
2 ' the bounds of the array.
4 Imports System
6 Module Array3
8 Sub Main()
9 Dim arr As Integer(,) = {{1, 2, 3}, {3, 4, 7}}
10 arr(0, 2) = arr(0, 0) * arr(0, 1)
11 arr(1, 2) = arr(1, 0) * arr(1, 1)
12 If arr(0, 2) <> 2 Or arr(1, 2) <> 12 Then
13 Throw New Exception("#A1 - Array Handling Statement failed")
14 End If
15 ReDim Preserve arr(1, 1)
16 arr(1, 2) = 2
17 End Sub
19 End Module