Comments
2 comments
-
More bad cases.
3.int num; for (num = 0; num < 1; num++) { } for (num = 0; num < 1; num++) { }
converted toDim num As Integer num For num = 0 To 1 - 1 Next num num For num = 0 To 1 - 1 Next num
4. All C# event declarations (.event/.addon/.removeon) are shown in VB.NET as Custom Event, but without AddHandler/RemoveHandler. The handlers themselves, get_OnFoo/set_OnFoo, can be viewed as ordinary class methods in Reflector and are not emitted on export. The exported code can apparently be fixed by just removing Custom keyword.
5. Foo(i++) in C# gets translated to VB.NET just as Foo(i++), but VB.NET doesn't have this syntax.
6.(value != this.m_colors[this.m_selindex])) ' operands are Color
was translated to(Not value Is Me.m_colors.Item(Me.m_selindex)))
(and Is is not applicable to Color), though I can't write a trivial testcase. IL has "call bool [System.Drawing]System.Drawing.Color::op_Equality".
7.Module module = Assembly.GetExecutingAssembly().GetModules()[0];
converted toDim module As Module = Assembly.GetExecutingAssembly.GetModules(0)
Two errors here: "Module" should be escaped and GetModules(0) should be GetModules()(0). -
Thanks for reporting these issues - I've logged them as RP-731.
Add comment
Please sign in to leave a comment.
Second, the following C# code is disassembled incorrectly:
With 3.5 target it gets disassembled to VB.NET as