as3hx icon indicating copy to clipboard operation
as3hx copied to clipboard

For consistent porting set default values if not set other (Int,Bool,Float at least)

Open andrew-git opened this issue 7 years ago • 0 comments

as3 code for example:

package {
    public class Issue {
        private var i:int;
        private var f:Number;
        private var b:Boolean;
        private var s:String;
        public function Issue() {
            //code here...
        }
    }
}

expected result


class Issue
{
    private var i:Int = 0;
    private var f:Float = Math.NaN;
    private var b:Bool = false;
    private var s:String = null;
    public function new()
    {
        //code here...
    }
}

actual result


class Issue
{

    private var i:Int;
    private var f:Float;
    private var b:Bool;
    private var s:String;
    public function new()
    {
        //code here...
    }
}

andrew-git avatar Oct 06 '18 14:10 andrew-git