xsharp.eu • XPorter/VO wish
Page 1 of 1

XPorter/VO wish

Posted: Sun Sep 02, 2018 12:14 pm
by wriedmann
Hi Chris,

to make the migration from VO to X# easier, and also make it easier to have the same code running in X# and VO, it would be very welcome to have a possibility to translate/xport code on the fly.
For this, the XPorter/VO should offer a input control where to paste VO code (copied over from VO), translate it to X# to paste it then over to X# (both XIDE and VS source code editor).

That would be a great help for people like me that has tons of VO code, and for sure will have several years of coexistence of native VO applications and ported ones.

Currently, when I'm adapting VO code to X#, I have to apply the changes on both sides to not need continuosly xporting the entire application.

And I use extensively the external modules maintain code synchronized between different VO applications, and when I move some of them over to X# (first Windows services and console mode applications), I need a possibility to migrate module-wise (or file-wise, when it comes to X#).

Wolfgang

XPorter/VO wish

Posted: Sun Sep 02, 2018 5:08 pm
by Chris
Hi Wolfgang,

Actually the VOXporter does very very few (almost zero) changes to regular code, the X# compiler is so compatible to VO that this not necessary (unlike vulcan's Transporter which was doing a lot of changes).

The changes that it actually makes cannot be done in just a small snippet of code, the tool adjusts things like callback functions, adds missing constructors and things like that, but on order to do those, it needs to have access to the whole application code.

Chris

XPorter/VO wish

Posted: Mon Sep 03, 2018 4:05 am
by wriedmann
Hi Chris,

I don't need that for small snippets of code, but for an entire module. The VOXporter makes some changes, like renaming the "method Init()" to "Constructor", grouping the classes together with the methods and a few other changes, but it does not removes the "return self" from the constructor (as the Transporter did), and don't even the return value from the assign methods.

Having the possibility to xport an entire module (using copy/paste) would help a lot. Of course then references cannot be set, but it would help to speed up the process - and is something automated.

Wolfgang

XPorter/VO wish

Posted: Mon Sep 03, 2018 10:05 am
by Chris
Hi Wolfgang,

OK, will have a look, but unfortunately it is not as easy as it may sound. It will need enough refactoring to decouple the app wide changes from the single file changes. Probably a completely different special version for this would be easier to implement, will get back to you about this.

Chris

XPorter/VO wish

Posted: Mon Sep 03, 2018 11:22 am
by wriedmann
Hi Chris,

thank you very much!

Indeed this is very important - hopefully not only for me, but for everyone working in step-by-step VO migrations.

Wolfgang

XPorter/VO wish

Posted: Mon Sep 03, 2018 4:26 pm
by ic2
I actually like the idea, although I realize that it will of course not be so easy as it sounds.
It would allow me to do the main programming in VO and easily transfer the code to X# when it's about ready. As everything goes much faster in VO it would safe me a lot of time while still being able to quickly convert tested & ready methods to X#. It would be easier than rerunning XPorter for the whole project.

Drawback is that I won't use anything added to X# which is not present in VO. But I rarely do that anyway. Main advantage for X# projects for us is that they will be more future proof & access to code in the same library which can do more/is better for .Net than for VO. That code is (now) mainly C# code which usually started as some sample on Stackoverflow, Codeproject etc.

Dick