Hi Kees,
I think it's better to just enable the /vo2 option, this is why we introduced it, to help porting applications from VO.
In VO, not only NULL_STRING practically means "", but all locals and class variables are also used like that:
Code: Select all
FUNCTION Start() AS INT
LOCAL c AS STRING
LOCAL o AS TestClass
? c == "" // TRUE
o := TestClass{}
? o:c == "" // TRUE
RETURN 0
CLASS TestClass
EXPORT c AS STRING
END CLASS
When you enable the /vo2 option in X#, the compiler mimics also this behavior. If you do not initialize (or forget to do that) all such vars to "" in X#, all sorts of problems may arise (at runtime...) in cases where your VO code relies on that.
So I'd suggest to just enable the option, nothing wrong about it, it only makes code say 0.001% slower... If you write a new .Net app, it's probably better to not use it, but even if you want to enable it also in this case, there's nothing wrong with it.