[Mono-devel-list] MSVB conversion from C# to Mbas status

Dennis Hayes denisraytek at yahoo.com
Tue Feb 22 01:40:16 EST 2005


These 28 files convert easily

AppWinStyle.vb
AssemblyInfo.vb
BooleanType.vb
ByteType.vb
CallType.vb
ComClassAttribute.vb
CompareMethod.vb
DateFormat.vb
DateInterval.vb
DateType.vb
DefaultArgumentValueAttribute.vb
DoubleType.vb
DueDate.vb
FirstDayOfWeek.vb
FirstWeekOfYear.vb
Globals.vb
MsgBoxResult.vb
MsgBoxStyle.vb
OpenMode.vb
OptionCompareAttribute.vb
OptionTextAttribute.vb
SpcInfo.vb
StandardModuleAttribute.vb
TabInfo.vb
TODOAttribute.vb
VBErrors.vb
VBFixedArrayAttribute.vb
VBFixedStringAttribute.vb

 

these 48 require significant effort (or depend on another file that requires effort)

BaseVBFile.vb
BinaryVBFile.vb
CallType.vb
CharArrayType.vb
CharType.vb
Collection.vb
Constants.vb
ControlChars.vb
Conversion.vb
DateAndTime.vb
DecimalType.vb
ErrObject.vb
ExceptionUtils.vb
FileAttribute.vb
FileSystem.vb
Financial.vb
FlowControl.vb
ForEachEnum.vb
HostServices.vb
IncompleteInitialization.vb
Information.vb
InputVBFile.vb
IntegerType.vb
Interaction.vb
IVbHost.vb
LateBinding.vb
LongType.vb
MsgBoxStyle.vb
ObjectType.vb
OpenAccess.vb
OpenMode.vb
OpenShare.vb
OutPutVBFile.vb
ProjectData.vb
RandomVBFile.vb
ShortType.vb
SingleType.vb
StaticLocalInitFlag.vb
Strings.vb
StringType.vb
TriState.vb
Utils.vb
VariantType.vb
VBBinder.vb
VBFile.vb
VBMath.vb
VbStrConv.vb
VBUtils.vb

Top issues uncovered thus far

1) Mbas does not yet support #ifdef, easy to work around.

2) The converter converts else if to else if, works in VB, mbas requires single word elseif, easy to work around. The converter could do a better job on this as well.

3) Basic keywords used as variable names (example type enum has String as an entry)

4) Neither VB nor mbas supports some abstract get's. I think. I have not looked into these errors at all.

5) Some files crash mbas with internal compiler errors. Some or all of these could be caused by illeage syntax in the converted code.

6) Default objects cause errors. Could be mbas, the converter, or just something that needs to be done by hand. (“.Length” is used with out an object i.e. not myobject.Length. In foreach loops?).

7) Assignments in expressions myfunction(x += 5). These will be some of the first changes I make in the C# code.

8) In at least one case, the converter uses the MSVB function it is converting to do the converting. WE use Cint(mychar) in a char to int conversion. The Cint function is replaced with the MSVB function. I expect to replace this with a call to System.Convert, with changes as needed to get the same behavior.

9) Some classes have no namespace declared.

10) Some classes import/uses their own namespace.

It will probably be a week or two before I do much more on this. At that point, I will probably fix #7, 8, 9, 10 in the SVN C# code, and file some bugs with the converter tool people.

Feasibility:

1) Looks good at some point.

2) Maturity of mbas will be the key constraint

3) At some point I will (should ;)) make test cases for related mbas issues.

4) The tool does a good job of doing most of the conversion. Issues with mbas and the tool require some easy work arounds. Fewer than a dozen tough problems appear repeatedly.

Dennis

 

 

 


 


		
---------------------------------
Do you Yahoo!?
 Yahoo! Search presents - Jib Jab's 'Second Term'
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20050221/0911fa0f/attachment.html 


More information about the Mono-devel-list mailing list