**** Merged from MCS ****
[mono-project.git] / mcs / btests / RelationalOperators.vb
blobdc29dd73537e715f3dc0fe2cd0b9e1b7b02ba36f
2 Imports System
4 Module M1
6 Sub Main()
7 Console.WriteLine(f1())
8 End Sub
10 Function f1() As Integer
12 Dim a As Long = 0
13 Dim arr(17) As Boolean
15 If a < System.Int64.MaxValue Then
16 arr(0) = True
17 End If
19 If a <= System.Int64.MaxValue Then
20 arr(1) = True
21 End If
23 If System.Int64.MaxValue > a Then
24 arr(2) = True
25 End If
27 If System.Int64.MaxValue >= a Then
28 arr(3) = True
29 End If
31 If a <> System.Int64.MaxValue Then
32 arr(4) = True
33 End If
35 If a = System.Int64.MaxValue Then arr(5) = False Else arr(5) = True
37 Dim b As Double = 0.0F
39 If b < System.Double.MaxValue Then
40 arr(6) = True
41 End If
43 If b <= System.Double.MaxValue Then
44 arr(7) = True
45 End If
47 If System.Double.MaxValue > b Then
48 arr(8) = True
49 End If
51 If System.Double.MaxValue >= b Then
52 arr(9) = True
53 End If
55 If b <> System.Double.MaxValue Then
56 arr(10) = True
57 End If
59 If b = System.Double.MaxValue Then arr(11) = False Else arr(11) = True
61 Dim c As Decimal = 0D
63 If c < System.Decimal.MaxValue Then
64 arr(12) = True
65 End If
67 If c <= System.Decimal.MaxValue Then
68 arr(13) = True
69 End If
71 If System.Decimal.MaxValue > c Then
72 arr(14) = True
73 End If
75 If System.Decimal.MaxValue >= c Then
76 arr(15) = True
77 End If
79 If c <> System.Decimal.MaxValue Then
80 arr(16) = True
81 End If
83 If c = System.Decimal.MaxValue Then arr(17) = False Else arr(17) = True
85 Console.WriteLine("Array length: {0}", arr.GetUpperBound(0))
86 For i As Integer = 0 To arr.GetUpperBound(0)
87 Console.Write("i: {0} ", i)
88 Console.WriteLine(arr(i))
89 Next
91 For Each bval As Boolean In arr
92 If Not bval Then
93 Return 1
94 End If
95 Next
97 Return 0
99 End Function
102 End Module