Updated project.
[mono.git] / mcs / btests / FunctionArgu_ByReferenceB.vb
1 '=============================================================================================\r
2 'Name:Manish Kumar Sinha \r
3 'Email Address: manishkumarsinha@sify.com\r
4 'Test Case Name: Argument passing by Reference:\r
5 'APR-1.4.0: If procedure is define by passing argument by reference and while calling the\r
6 '                procedure it is passes by giving parentheses around the variable then it protect\r
7 '                it from change \r
8 '=============================================================================================\r
9 \r
10 Imports System\r
11 Module APR_1_4_0\r
12         Function F(ByRef p As Integer) as Integer\r
13       p += 1\r
14         return p\r
15    End Function \r
16    \r
17    Sub Main()\r
18       Dim a As Integer = 1\r
19         Dim b As Integer = 0\r
20       b=F((a))\r
21                 if(b=a)\r
22                 Throw new System.Exception ("#A1, Unexpected behavior in Arguments_ByReferenceB.vb")\r
23                 end if\r
24    End Sub \r
25 End Module\r
26 '=============================================================================================