From: Kruch <kr...@se...> - 2013-06-12 13:34:14
|
Hello, I've tried to compile from java to csharp (for j2me -> WP8 app conversion using CodenameOne framework). I wonder about two things I noticed. 1) types vs casting When I check generated xml, types of params and vars etc are known, however in generated C# everything is System.Object that is cast to correspoding type _everytime_ instance is accessed. Is this by intention? 2) I get wrong class types for exception caught in synchronized blocks which are rethrowed just after the block ends: <dex:throw vx="0" vx-type="java.lang.Class" class-type="java.lang.Class" /> -> throw new global::org.xmlvm._nExceptionAdapter((global::java.lang.Class) _r0 _o); This result in ClassCastException thrown at runtime. I've workarounded in the xml2cshapr.xsl, but it looks like a bug to me. Thanks, Ales |