[mono-vb] assignment generates Invalid IL code ????
col48
all4bus at 12freeukisp.co.uk
Fri Jun 12 16:59:15 EDT 2009
Monodevelop 1.0 in Ubuntu 8.04.
The following simple code (first steps in Mono VB!) builds but fails with
this Application output.
Unhandled Exception: System.InvalidProgramException: Invalid IL code in
Application:Main (): IL_000c: ldarg.0
@@@ code starts here @@@
' Application.vb created with MonoDevelop
' User: (etc)
'
' To change standard headers go to Edit->Preferences->Coding->Standard
Headers
'
Public Class Application
Public Shared Sub Main()
dim g_PossMoves as typ_Move
dim xx as integer
xx = 2
System.Console.WriteLine("Hello A")
xx = initMoves() '<<<
System.Console.WriteLine("Hello world!")
End Sub
function initMoves() as integer
System.Console.WriteLine("Hi2")
initMoves = 3
System.Console.WriteLine("Hi3")
end function
End Class
public structure typ_Move
(more lines ended by end structure statement)
@@@ code ends here @@@
If I comment out the line marked with <<< the code runs OK.
I have tried turning the function into a sub with appropriate changes when
invoking it but that makes no difference :,(
So can anyone tell me what I am doing wrong?????
--
View this message in context: http://www.nabble.com/assignment-generates-Invalid-IL-code------tp24005991p24005991.html
Sent from the Mono - VB mailing list archive at Nabble.com.
More information about the Mono-vb
mailing list