Updated project.
[mono.git] / mcs / btests / ConditionalStatementsA.vb
1 Imports System\r
2 \r
3 Module ConditionalStatementsA\r
4 \r
5         Sub Main()\r
6 \r
7                 Dim i As Integer = 0\r
8 \r
9                 if i = 0 then i = 1\r
10 \r
11                 if i <> 1 then throw new exception("#CSA1") else i = 2\r
12                 \r
13                 if i = 1 then else i = 3\r
14 \r
15                 if i <> 3 then i = 2 else    ' Should give compile time error\r
16 \r
17                 if i <> 2\r
18                         i = 3\r
19                 end if\r
20                                 \r
21                 if i = 3\r
22                 end if\r
23                                 \r
24                 if i <> 3\r
25                         throw new exception("#CSA2")   \r
26                 else\r
27                         i = 4\r
28                 end if\r
29 \r
30                 if i <> 4 then\r
31                         throw new exception("#CSA3")\r
32                 elseif i = 4\r
33                         i = 5\r
34                 end if\r
35 \r
36                 if i <> 5\r
37                         throw new exception("#CSA4") \r
38                 elseif i = 6\r
39                         throw new exception("#CSA5")\r
40                 elseif i = 5 then\r
41                         i = 6\r
42                 else\r
43                         throw new exception("#CSA6")\r
44                 end if\r
45                 \r
46         End Sub\r
47         \r
48 End Module