浏览代码

whitespaces

Simon Krajewski 9 年之前
父节点
当前提交
b62851cd83
共有 100 个文件被更改,包括 932 次插入932 次删除
  1. 9 9
      tests/unit/src/unit/MyAbstract.hx
  2. 3 3
      tests/unit/src/unit/MySpodClass.hx
  3. 10 10
      tests/unit/src/unit/Test.hx
  4. 37 37
      tests/unit/src/unit/TestCSharp.hx
  5. 10 10
      tests/unit/src/unit/TestDCE.hx
  6. 6 6
      tests/unit/src/unit/TestInt64.hx
  7. 30 30
      tests/unit/src/unit/TestJQuery.hx
  8. 9 9
      tests/unit/src/unit/TestJava.hx
  9. 97 97
      tests/unit/src/unit/TestJson.hx
  10. 19 19
      tests/unit/src/unit/TestPhp.hx
  11. 5 5
      tests/unit/src/unit/TestPython.hx
  12. 4 4
      tests/unit/src/unit/TestSpecification.hx
  13. 55 55
      tests/unit/src/unit/TestUInt.hx
  14. 4 4
      tests/unit/src/unit/TestXML.hx
  15. 1 1
      tests/unit/src/unit/hxcpp_issues/Issue189.hx
  16. 8 8
      tests/unit/src/unit/hxcpp_issues/Issue193.hx.disabled
  17. 4 4
      tests/unit/src/unit/hxcpp_issues/Issue225.hx
  18. 1 1
      tests/unit/src/unit/hxcpp_issues/String.hx
  19. 2 2
      tests/unit/src/unit/issues/Issue1497.hx
  20. 18 18
      tests/unit/src/unit/issues/Issue1827.hx
  21. 2 2
      tests/unit/src/unit/issues/Issue1925.hx
  22. 8 8
      tests/unit/src/unit/issues/Issue1997.hx
  23. 1 1
      tests/unit/src/unit/issues/Issue2044.hx
  24. 5 5
      tests/unit/src/unit/issues/Issue2085.hx
  25. 21 21
      tests/unit/src/unit/issues/Issue2130.hx
  26. 10 10
      tests/unit/src/unit/issues/Issue2157.hx
  27. 12 12
      tests/unit/src/unit/issues/Issue2224.hx
  28. 5 5
      tests/unit/src/unit/issues/Issue2235.hx
  29. 21 21
      tests/unit/src/unit/issues/Issue2236.hx
  30. 2 2
      tests/unit/src/unit/issues/Issue2281.hx
  31. 2 2
      tests/unit/src/unit/issues/Issue2282.hx
  32. 4 4
      tests/unit/src/unit/issues/Issue2343.hx
  33. 2 2
      tests/unit/src/unit/issues/Issue2380.hx
  34. 30 30
      tests/unit/src/unit/issues/Issue2396.hx
  35. 2 2
      tests/unit/src/unit/issues/Issue2401.hx
  36. 2 2
      tests/unit/src/unit/issues/Issue2409.hx
  37. 2 2
      tests/unit/src/unit/issues/Issue2478.hx
  38. 2 2
      tests/unit/src/unit/issues/Issue2508.hx.disabled
  39. 2 2
      tests/unit/src/unit/issues/Issue2540.hx
  40. 2 2
      tests/unit/src/unit/issues/Issue2580.hx
  41. 14 14
      tests/unit/src/unit/issues/Issue2581.hx
  42. 5 5
      tests/unit/src/unit/issues/Issue2584.hx
  43. 2 2
      tests/unit/src/unit/issues/Issue2587.hx
  44. 4 4
      tests/unit/src/unit/issues/Issue2607.hx
  45. 3 3
      tests/unit/src/unit/issues/Issue2614.hx
  46. 4 4
      tests/unit/src/unit/issues/Issue2627.hx
  47. 9 9
      tests/unit/src/unit/issues/Issue2633.hx
  48. 5 5
      tests/unit/src/unit/issues/Issue2639.hx
  49. 3 3
      tests/unit/src/unit/issues/Issue2653.hx
  50. 10 10
      tests/unit/src/unit/issues/Issue2664.hx
  51. 2 2
      tests/unit/src/unit/issues/Issue2668.hx.disabled
  52. 2 2
      tests/unit/src/unit/issues/Issue2685.hx
  53. 4 4
      tests/unit/src/unit/issues/Issue2696.hx
  54. 6 6
      tests/unit/src/unit/issues/Issue2698.hx
  55. 5 5
      tests/unit/src/unit/issues/Issue2712.hx
  56. 3 3
      tests/unit/src/unit/issues/Issue2735.hx
  57. 15 15
      tests/unit/src/unit/issues/Issue2736.hx
  58. 8 8
      tests/unit/src/unit/issues/Issue2750.hx
  59. 1 1
      tests/unit/src/unit/issues/Issue2763.hx
  60. 6 6
      tests/unit/src/unit/issues/Issue2766.hx
  61. 8 8
      tests/unit/src/unit/issues/Issue2778.hx
  62. 11 11
      tests/unit/src/unit/issues/Issue2786.hx
  63. 25 25
      tests/unit/src/unit/issues/Issue2792.hx
  64. 13 13
      tests/unit/src/unit/issues/Issue2810.hx
  65. 10 10
      tests/unit/src/unit/issues/Issue2859.hx
  66. 3 3
      tests/unit/src/unit/issues/Issue2871.hx
  67. 3 3
      tests/unit/src/unit/issues/Issue2902.hx
  68. 19 19
      tests/unit/src/unit/issues/Issue2951.hx
  69. 12 12
      tests/unit/src/unit/issues/Issue2958.hx
  70. 2 2
      tests/unit/src/unit/issues/Issue2963.hx
  71. 4 4
      tests/unit/src/unit/issues/Issue2979.hx
  72. 1 1
      tests/unit/src/unit/issues/Issue2980.hx
  73. 5 5
      tests/unit/src/unit/issues/Issue2982.hx
  74. 7 7
      tests/unit/src/unit/issues/Issue2988.hx
  75. 4 4
      tests/unit/src/unit/issues/Issue3005.hx
  76. 1 1
      tests/unit/src/unit/issues/Issue3008.hx
  77. 1 1
      tests/unit/src/unit/issues/Issue3023.hx
  78. 2 2
      tests/unit/src/unit/issues/Issue3029.hx
  79. 5 5
      tests/unit/src/unit/issues/Issue3033.hx.disabled
  80. 4 4
      tests/unit/src/unit/issues/Issue3042.hx
  81. 2 2
      tests/unit/src/unit/issues/Issue3061.hx
  82. 2 2
      tests/unit/src/unit/issues/Issue3063.hx
  83. 48 48
      tests/unit/src/unit/issues/Issue3071.hx
  84. 5 5
      tests/unit/src/unit/issues/Issue3081.hx
  85. 60 60
      tests/unit/src/unit/issues/Issue3088.hx
  86. 1 1
      tests/unit/src/unit/issues/Issue3090.hx
  87. 5 5
      tests/unit/src/unit/issues/Issue3113.hx
  88. 7 7
      tests/unit/src/unit/issues/Issue3115.hx
  89. 5 5
      tests/unit/src/unit/issues/Issue3133.hx
  90. 8 8
      tests/unit/src/unit/issues/Issue3138.hx
  91. 12 12
      tests/unit/src/unit/issues/Issue3197.hx
  92. 19 19
      tests/unit/src/unit/issues/Issue3198.hx
  93. 1 1
      tests/unit/src/unit/issues/Issue3214.hx
  94. 3 3
      tests/unit/src/unit/issues/Issue3217.hx
  95. 1 1
      tests/unit/src/unit/issues/Issue3218.hx
  96. 2 2
      tests/unit/src/unit/issues/Issue3244.hx
  97. 6 6
      tests/unit/src/unit/issues/Issue3280.hx
  98. 18 18
      tests/unit/src/unit/issues/Issue3292.hx
  99. 2 2
      tests/unit/src/unit/issues/Issue3333.hx
  100. 5 5
      tests/unit/src/unit/issues/Issue3338.hx

+ 9 - 9
tests/unit/src/unit/MyAbstract.hx

@@ -2,17 +2,17 @@ package unit;
 
 abstract MyAbstract(Int) {
 
-    public inline function new(x) {
-        this = x;
-    }
+	public inline function new(x) {
+		this = x;
+	}
 
-    public inline function incr() {
-        return ++this;
-    }
+	public inline function incr() {
+		return ++this;
+	}
 
-    public inline function toInt() : Int {
-        return this;
-    }
+	public inline function toInt() : Int {
+		return this;
+	}
 
 }
 

+ 3 - 3
tests/unit/src/unit/MySpodClass.hx

@@ -86,9 +86,9 @@ abstract AbstractSpodTest<A>(A) from A
 
 //issue #3828
 @:keep @:skip class BaseIssueC3828 extends sys.db.Object {
-    public var id : SInt;
-    @:relation(ruid)
-    public var refUser : SNull<IssueC3828>;
+	public var id : SInt;
+	@:relation(ruid)
+	public var refUser : SNull<IssueC3828>;
 }
 
 @:keep class IssueC3828 extends BaseIssueC3828 {

+ 10 - 10
tests/unit/src/unit/Test.hx

@@ -185,9 +185,9 @@ class Test {
 	}
 
    static function logVerbose(msg:String) {
-      #if (cpp || neko || php)
-      Sys.println(msg);
-      #end
+	  #if (cpp || neko || php)
+	  Sys.println(msg);
+	  #end
    }
 
 	static var count = 0;
@@ -276,7 +276,7 @@ class Test {
 	}
 
 	static function main() {
-      var verbose = #if ( cpp || neko || php ) Sys.args().indexOf("-v") >= 0 #else false #end;
+	  var verbose = #if ( cpp || neko || php ) Sys.args().indexOf("-v") >= 0 #else false #end;
 
 		#if cs //"Turkey Test" - Issue #996
 		cs.system.threading.Thread.CurrentThread.CurrentCulture = new cs.system.globalization.CultureInfo('tr-TR');
@@ -367,8 +367,8 @@ class Test {
 				database : "haxe_test" })));
 		}
 		#end
-      if (verbose)
-         logVerbose("Setup sqlite");
+	  if (verbose)
+		 logVerbose("Setup sqlite");
 		classes.push(new TestSpod(sys.db.Sqlite.open("db.db3")));
 		#end
 		TestIssues.addIssueClasses("src/unit/issues", "unit.issues");
@@ -381,12 +381,12 @@ class Test {
 			asyncWaits.push(null);
 			for( inst in classes ) {
 				current = Type.getClass(inst);
-            if (verbose)
-               logVerbose("Class " + Std.string(current) );
+			if (verbose)
+			   logVerbose("Class " + Std.string(current) );
 				for( f in Type.getInstanceFields(current) )
 					if( f.substr(0,4) == "test" ) {
-                  if (verbose)
-                     logVerbose("   " + f);
+				  if (verbose)
+					 logVerbose("   " + f);
 						#if fail_eager
 						Reflect.callMethod(inst,Reflect.field(inst,f),[]);
 						#else

+ 37 - 37
tests/unit/src/unit/TestCSharp.hx

@@ -774,47 +774,47 @@ private class TestMyClass extends haxe.test.MyClass
 
 private interface IEventIface {
 	@:keep
-    @:event private var IfaceEvent1:Action_1<Int>;
-    function add_IfaceEvent1(cb:Action_1<Int>):Void;
-    function remove_IfaceEvent1(cb:Action_1<Int>):Void;
-
-    @:keep
-    @:event private var IfaceEvent2:Action_1<Int>;
-    function add_IfaceEvent2(cb:Action_1<Int>):Void;
-    function remove_IfaceEvent2(cb:Action_1<Int>):Void;
+	@:event private var IfaceEvent1:Action_1<Int>;
+	function add_IfaceEvent1(cb:Action_1<Int>):Void;
+	function remove_IfaceEvent1(cb:Action_1<Int>):Void;
+
+	@:keep
+	@:event private var IfaceEvent2:Action_1<Int>;
+	function add_IfaceEvent2(cb:Action_1<Int>):Void;
+	function remove_IfaceEvent2(cb:Action_1<Int>):Void;
 }
 
 @:publicFields
 private class EventClass implements IEventIface {
 	function new() {}
 
-    @:event private var Event1:Action_1<Int>;
-    function add_Event1(cb:Action_1<Int>) {}
-    function remove_Event1(cb:Action_1<Int>) {}
-    function invokeEvent1(i) if (Event1 != null) Event1.Invoke(i);
-
-    @:event private var Event2:Action_1<Int>;
-    var event2Counter = 0;
-    function add_Event2(cb:Action_1<Int>) event2Counter++;
-    function remove_Event2(cb:Action_1<Int>) event2Counter--;
-
-    @:event private static var SEvent1:Action_1<Int>;
-    static function add_SEvent1(cb:Action_1<Int>) {}
-    static function remove_SEvent1(cb:Action_1<Int>) {}
-    static function invokeSEvent1(i) if (SEvent1 != null) SEvent1.Invoke(i);
-
-    @:event private static var SEvent2:Action_1<Int>;
-    static var sEvent2Counter = 0;
-    static function add_SEvent2(cb:Action_1<Int>) sEvent2Counter++;
-    static function remove_SEvent2(cb:Action_1<Int>) sEvent2Counter--;
-
-    @:event private var IfaceEvent1:Action_1<Int>;
-    function add_IfaceEvent1(cb:Action_1<Int>) {}
-    function remove_IfaceEvent1(cb:Action_1<Int>) {}
-    function invokeIfaceEvent1(i) if (IfaceEvent1 != null) IfaceEvent1.Invoke(i);
-
-    @:event private var IfaceEvent2:Action_1<Int>;
-    var ifaceEvent2Counter = 0;
-    function add_IfaceEvent2(cb:Action_1<Int>) ifaceEvent2Counter++;
-    function remove_IfaceEvent2(cb:Action_1<Int>) ifaceEvent2Counter--;
+	@:event private var Event1:Action_1<Int>;
+	function add_Event1(cb:Action_1<Int>) {}
+	function remove_Event1(cb:Action_1<Int>) {}
+	function invokeEvent1(i) if (Event1 != null) Event1.Invoke(i);
+
+	@:event private var Event2:Action_1<Int>;
+	var event2Counter = 0;
+	function add_Event2(cb:Action_1<Int>) event2Counter++;
+	function remove_Event2(cb:Action_1<Int>) event2Counter--;
+
+	@:event private static var SEvent1:Action_1<Int>;
+	static function add_SEvent1(cb:Action_1<Int>) {}
+	static function remove_SEvent1(cb:Action_1<Int>) {}
+	static function invokeSEvent1(i) if (SEvent1 != null) SEvent1.Invoke(i);
+
+	@:event private static var SEvent2:Action_1<Int>;
+	static var sEvent2Counter = 0;
+	static function add_SEvent2(cb:Action_1<Int>) sEvent2Counter++;
+	static function remove_SEvent2(cb:Action_1<Int>) sEvent2Counter--;
+
+	@:event private var IfaceEvent1:Action_1<Int>;
+	function add_IfaceEvent1(cb:Action_1<Int>) {}
+	function remove_IfaceEvent1(cb:Action_1<Int>) {}
+	function invokeIfaceEvent1(i) if (IfaceEvent1 != null) IfaceEvent1.Invoke(i);
+
+	@:event private var IfaceEvent2:Action_1<Int>;
+	var ifaceEvent2Counter = 0;
+	function add_IfaceEvent2(cb:Action_1<Int>) ifaceEvent2Counter++;
+	function remove_IfaceEvent2(cb:Action_1<Int>) ifaceEvent2Counter--;
 }

+ 10 - 10
tests/unit/src/unit/TestDCE.hx

@@ -119,11 +119,11 @@ class TestDCE extends Test {
 
 	#if (!cpp && !java && !cs)
 	public function testProperty2() {
-        var a = new RemovePropertyKeepAccessors();
-        a.test = 3;
-        eq(a.test, 3);
-        Reflect.setProperty(a, "test", 2);
-        eq(a.test, 2);
+		var a = new RemovePropertyKeepAccessors();
+		a.test = 3;
+		eq(a.test, 3);
+		Reflect.setProperty(a, "test", 2);
+		eq(a.test, 2);
 
 		var c = Type.resolveClass("unit.RemovePropertyKeepAccessors");
 		hf(c, "get_test");
@@ -236,11 +236,11 @@ class ThrownWithToString {
 
 class RemovePropertyKeepAccessors
 {
-    public function new() {}
+	public function new() {}
 
-    var _test:Float;
-    public var test(get, set):Float;
+	var _test:Float;
+	public var test(get, set):Float;
 
-    public function get_test():Float return _test;
-    public function set_test(a:Float):Float { _test = a; return _test; }
+	public function get_test():Float return _test;
+	public function set_test(a:Float):Float { _test = a; return _test; }
 }

+ 6 - 6
tests/unit/src/unit/TestInt64.hx

@@ -234,8 +234,8 @@ class TestInt64 extends Test {
 
 		// Issue #1532
 		a = Int64.make(0xFFF21CDA, 0x972E8BA3);
-    	b = Int64.make(0x0098C29B, 0x81000001);
-    	int64eq( a*b, Int64.make(0xDDE8A2E8, 0xBA2E8BA3) );
+		b = Int64.make(0x0098C29B, 0x81000001);
+		int64eq( a*b, Int64.make(0xDDE8A2E8, 0xBA2E8BA3) );
 
 		// Int64*Int
 		a = Int64.make(0x01000000, 0x11131111);
@@ -363,7 +363,7 @@ class TestInt64 extends Test {
 	public function testCapture()
 	{
 		var a = Int64.make(0xFF00FF00,0xF0F0F0F0),
-		    b = Int64.make(0xFF00FF00,0xF0F0F0F0);
+			b = Int64.make(0xFF00FF00,0xF0F0F0F0);
 		eq(a.compare(b), 0);
 		eq(a.high, 0xFF00FF00);
 		function test() return Int64.compare(a,Int64.make(0xFF00FF00,0xF0F0F0F0));
@@ -400,7 +400,7 @@ class TestInt64 extends Test {
 
 	public function testCompare() {
 		var a = ofInt(2),
-		    b = ofInt(3);
+			b = ofInt(3);
 		t(a == a);
 		t(b == b);
 		eq(a.compare(a), 0);
@@ -411,8 +411,8 @@ class TestInt64 extends Test {
 	public function testBits() {
 		var x = make(0xfedcba98,0x76543210);
 		var y = x.and((ofInt(0xffff))),
-		    z = x.or((ofInt(0xffff))),
-		    w = x.xor((make(0xffffffff,0xffffffff)));
+			z = x.or((ofInt(0xffff))),
+			w = x.xor((make(0xffffffff,0xffffffff)));
 		eq(y.toStr(), '12816');
 		eq(z.toStr(), '-81985529216434177');
 		eq(w.toStr(), '81985529216486895');

+ 30 - 30
tests/unit/src/unit/TestJQuery.hx

@@ -5,35 +5,35 @@ import js.jquery.Helper.*;
 
 class TestJQuery extends Test {
 
-    function testBasic() {
-        var j = new JQuery("<div></div>");
-        eq(j.length, 1);
-    }
-
-    function testRenamedStaticFields() {
-        JQuery.each([123], function(i, e) {
-            eq(i, 0);
-            eq(e, 123);
-        });
-    }
-
-    function testIterator() {
-        var div = Lambda.find(new JQuery("<div></div>"), function(ele) return ele.tagName.toLowerCase() == "div");
-        eq(div.tagName.toLowerCase(), "div");
-    }
-
-    function testHelper() {
-        var j = J("<div id='test'></div>");
-        j.each(function(i,e){
-            eq(JTHIS.attr("id"), "test");
-        });
-    }
-
-    function testVersion() {
-        var versionStr:String = JQuery.fn.jquery;
-        var v = versionStr.split(".");
-        eq(v.length, 3);
-        eq(haxe.macro.Compiler.getDefine("jquery_ver"), v[0] + StringTools.lpad(v[1], "0", 2) + StringTools.lpad(v[2], "0", 2));
-    }
+	function testBasic() {
+		var j = new JQuery("<div></div>");
+		eq(j.length, 1);
+	}
+
+	function testRenamedStaticFields() {
+		JQuery.each([123], function(i, e) {
+			eq(i, 0);
+			eq(e, 123);
+		});
+	}
+
+	function testIterator() {
+		var div = Lambda.find(new JQuery("<div></div>"), function(ele) return ele.tagName.toLowerCase() == "div");
+		eq(div.tagName.toLowerCase(), "div");
+	}
+
+	function testHelper() {
+		var j = J("<div id='test'></div>");
+		j.each(function(i,e){
+			eq(JTHIS.attr("id"), "test");
+		});
+	}
+
+	function testVersion() {
+		var versionStr:String = JQuery.fn.jquery;
+		var v = versionStr.split(".");
+		eq(v.length, 3);
+		eq(haxe.macro.Compiler.getDefine("jquery_ver"), v[0] + StringTools.lpad(v[1], "0", 2) + StringTools.lpad(v[2], "0", 2));
+	}
 
 }

+ 9 - 9
tests/unit/src/unit/TestJava.hx

@@ -17,16 +17,16 @@ class TestJava extends Test
 {
   function testException()
   {
-    var native = new NativeClass();
-    var hx:NativeClass = new HxClass();
+	var native = new NativeClass();
+	var hx:NativeClass = new HxClass();
 
-    exc(function() try native.excTest() catch (e:Dynamic) throw e);
-    var dyn:Dynamic = native;
-    exc(dyn.excTest);
+	exc(function() try native.excTest() catch (e:Dynamic) throw e);
+	var dyn:Dynamic = native;
+	exc(dyn.excTest);
 
-    try
-      hx.excTest()
-    catch(e:Dynamic) throw e; //shouldn't throw any exception
+	try
+	  hx.excTest()
+	catch(e:Dynamic) throw e; //shouldn't throw any exception
   }
 
 	public function testIssue2964()
@@ -354,7 +354,7 @@ private class TestMyClass extends haxe.test.MyClass
   @:throws("java.lang.Throwable")
   public function excTest():Void
   {
-    throw new java.lang.Throwable("test", null);
+	throw new java.lang.Throwable("test", null);
   }
 }
 

+ 97 - 97
tests/unit/src/unit/TestJson.hx

@@ -2,103 +2,103 @@ package unit;
 
 class TestJson extends Test {
 
-    function testNativeJson() {
-        var str = haxe.Json.stringify( { x : -4500, y : 1.456, a : ["hello", "wor'\"\n\t\rd"] } );
-        str = str.substr(1, str.length - 2); // remove {}
-        var parts = str.split(",");
-        t( parts.remove('"x":-4500') );
-        t( parts.remove('"y":1.456') );
-        t( parts.remove('"a":["hello"') );
-        t( parts.remove('"wor\'\\"\\n\\t\\rd"]') );
-        eq( parts.join("#"), "" );
-
-        function id(v:Dynamic,?pos:haxe.PosInfos) eq(haxe.Json.parse(haxe.Json.stringify(v)),v, pos);
-        function deepId(v:Dynamic) {
-            var str = haxe.Json.stringify(v);
-            eq(haxe.Json.stringify(haxe.Json.parse(str)), str);
-        }
-
-        id(true);
-        id(false);
-        id(null);
-        id(0);
-        id(145);
-        id( -145 );
-        id(0.15461);
-        id( -485.15461);
-        id( 1e10 );
-        id( -1e-10 );
-        id( "" );
-        id( "hello" );
-        id( "he\n\r\t\\\\llo");
-
-        deepId( {field: 4} );
-        deepId( { test: { nested: null }} );
-        var mix : Array<Dynamic> = [1, 2, 3, "str"];
-        deepId( {array: mix} );
-
-        eq( haxe.Json.parse('"\\u00E9"'), "é" );
-
-        eq(haxe.Json.stringify(Math.POSITIVE_INFINITY), "null");
-        eq(haxe.Json.stringify(Math.NEGATIVE_INFINITY), "null");
-        eq(haxe.Json.stringify(Math.NaN), "null");
-
-        return;
-    }
-
-    // TODO: test pretty-printing (also with objects with skipped function fields!)
-    function testHaxeJson() {
-        #if php
-        // php's haxe.Utf8 uses mbstring
-        if (untyped __call__("extension_loaded", "mbstring")) {
-        #end
-
-        var str = haxe.format.JsonPrinter.print( { x : -4500, y : 1.456, a : ["hello", "wor'\"\n\t\rd"], b : function() {} } );
-        str = str.substr(1, str.length - 2); // remove {}
-        var parts = str.split(",");
-        t( parts.remove('"x":-4500') );
-        t( parts.remove('"y":1.456') );
-        t( parts.remove('"a":["hello"') );
-        t( parts.remove('"wor\'\\"\\n\\t\\rd"]') );
-        eq( parts.join("#"), "" );
-
-        function id(v:Dynamic,?pos:haxe.PosInfos) eq(haxe.format.JsonParser.parse(haxe.format.JsonPrinter.print(v)),v);
-        function deepId(v:Dynamic) {
-            var str = haxe.format.JsonPrinter.print(v);
-            eq(haxe.format.JsonPrinter.print(haxe.format.JsonParser.parse(str)), str);
-        }
-
-        id(true);
-        id(false);
-        id(null);
-        id(0);
-        id(145);
-        id( -145 );
-        id(0.15461);
-        id( -485.15461);
-        id( 1e10 );
-        id( -1e-10 );
-        id( "" );
-        id( "hello" );
-        id( "he\n\r\t\\\\llo");
-
-        deepId( {field: 4} );
-        deepId( { test: { nested: null }} );
-        var mix : Array<Dynamic> = [1, 2, 3, "str"];
-        deepId( {array: mix} );
-
-        eq( haxe.format.JsonParser.parse('"\\u00E9"'), "é" );
-
-        eq(haxe.format.JsonPrinter.print(Math.POSITIVE_INFINITY), "null");
-        eq(haxe.format.JsonPrinter.print(Math.NEGATIVE_INFINITY), "null");
-        eq(haxe.format.JsonPrinter.print(Math.NaN), "null");
-        eq(haxe.format.JsonPrinter.print(function() {}), "\"<fun>\"");
-        eq(haxe.format.JsonPrinter.print({a: function() {}, b: 1}), "{\"b\":1}");
-
-        #if php
-        }
-        #end
-    }
+	function testNativeJson() {
+		var str = haxe.Json.stringify( { x : -4500, y : 1.456, a : ["hello", "wor'\"\n\t\rd"] } );
+		str = str.substr(1, str.length - 2); // remove {}
+		var parts = str.split(",");
+		t( parts.remove('"x":-4500') );
+		t( parts.remove('"y":1.456') );
+		t( parts.remove('"a":["hello"') );
+		t( parts.remove('"wor\'\\"\\n\\t\\rd"]') );
+		eq( parts.join("#"), "" );
+
+		function id(v:Dynamic,?pos:haxe.PosInfos) eq(haxe.Json.parse(haxe.Json.stringify(v)),v, pos);
+		function deepId(v:Dynamic) {
+			var str = haxe.Json.stringify(v);
+			eq(haxe.Json.stringify(haxe.Json.parse(str)), str);
+		}
+
+		id(true);
+		id(false);
+		id(null);
+		id(0);
+		id(145);
+		id( -145 );
+		id(0.15461);
+		id( -485.15461);
+		id( 1e10 );
+		id( -1e-10 );
+		id( "" );
+		id( "hello" );
+		id( "he\n\r\t\\\\llo");
+
+		deepId( {field: 4} );
+		deepId( { test: { nested: null }} );
+		var mix : Array<Dynamic> = [1, 2, 3, "str"];
+		deepId( {array: mix} );
+
+		eq( haxe.Json.parse('"\\u00E9"'), "é" );
+
+		eq(haxe.Json.stringify(Math.POSITIVE_INFINITY), "null");
+		eq(haxe.Json.stringify(Math.NEGATIVE_INFINITY), "null");
+		eq(haxe.Json.stringify(Math.NaN), "null");
+
+		return;
+	}
+
+	// TODO: test pretty-printing (also with objects with skipped function fields!)
+	function testHaxeJson() {
+		#if php
+		// php's haxe.Utf8 uses mbstring
+		if (untyped __call__("extension_loaded", "mbstring")) {
+		#end
+
+		var str = haxe.format.JsonPrinter.print( { x : -4500, y : 1.456, a : ["hello", "wor'\"\n\t\rd"], b : function() {} } );
+		str = str.substr(1, str.length - 2); // remove {}
+		var parts = str.split(",");
+		t( parts.remove('"x":-4500') );
+		t( parts.remove('"y":1.456') );
+		t( parts.remove('"a":["hello"') );
+		t( parts.remove('"wor\'\\"\\n\\t\\rd"]') );
+		eq( parts.join("#"), "" );
+
+		function id(v:Dynamic,?pos:haxe.PosInfos) eq(haxe.format.JsonParser.parse(haxe.format.JsonPrinter.print(v)),v);
+		function deepId(v:Dynamic) {
+			var str = haxe.format.JsonPrinter.print(v);
+			eq(haxe.format.JsonPrinter.print(haxe.format.JsonParser.parse(str)), str);
+		}
+
+		id(true);
+		id(false);
+		id(null);
+		id(0);
+		id(145);
+		id( -145 );
+		id(0.15461);
+		id( -485.15461);
+		id( 1e10 );
+		id( -1e-10 );
+		id( "" );
+		id( "hello" );
+		id( "he\n\r\t\\\\llo");
+
+		deepId( {field: 4} );
+		deepId( { test: { nested: null }} );
+		var mix : Array<Dynamic> = [1, 2, 3, "str"];
+		deepId( {array: mix} );
+
+		eq( haxe.format.JsonParser.parse('"\\u00E9"'), "é" );
+
+		eq(haxe.format.JsonPrinter.print(Math.POSITIVE_INFINITY), "null");
+		eq(haxe.format.JsonPrinter.print(Math.NEGATIVE_INFINITY), "null");
+		eq(haxe.format.JsonPrinter.print(Math.NaN), "null");
+		eq(haxe.format.JsonPrinter.print(function() {}), "\"<fun>\"");
+		eq(haxe.format.JsonPrinter.print({a: function() {}, b: 1}), "{\"b\":1}");
+
+		#if php
+		}
+		#end
+	}
 
 	function test3690() {
 		var strJson = haxe.Json.stringify( { x : -4500, y : 1.456, a : ["hello", "wor'\"\n\t\rd"] } );

+ 19 - 19
tests/unit/src/unit/TestPhp.hx

@@ -39,12 +39,12 @@ class TestPhp extends Test
 
 	function testIssue1828()
 	{
-        var x = try {
-            throw "foo";
-        } catch (e:String) {
-            true;
-        }
-        t(x);
+		var x = try {
+			throw "foo";
+		} catch (e:String) {
+			true;
+		}
+		t(x);
 	}
 
 	function testIssue1521()
@@ -61,20 +61,20 @@ class TestPhp extends Test
 }
 
 class Class2146 {
-    var array:Array<Class2146>;
-    function new() {
-        array = new Array<Class2146>();
-    }
+	var array:Array<Class2146>;
+	function new() {
+		array = new Array<Class2146>();
+	}
 
-    public static function test() {
-        var a = new Class2146();
-        var b = new Class2146();
-        var c = new Class2146();
-        a.array.push(b);
-        b.array.push(a);
-        c.array.push(a);
-        return Lambda.has(c.array,b);
-    }
+	public static function test() {
+		var a = new Class2146();
+		var b = new Class2146();
+		var c = new Class2146();
+		a.array.push(b);
+		b.array.push(a);
+		c.array.push(a);
+		return Lambda.has(c.array,b);
+	}
 }
 
 enum Annotation {

+ 5 - 5
tests/unit/src/unit/TestPython.hx

@@ -81,7 +81,7 @@ private interface IA {}
 private class A implements IA { }
 
 private class B extends A {
-    public function new() {}
+	public function new() {}
 }
 
 class TestPython extends Test {
@@ -144,8 +144,8 @@ class TestPython extends Test {
 	}
 
 	function testNativeClosures() {
-        var s = "foo";
-        var f = s.toUpperCase;
+		var s = "foo";
+		var f = s.toUpperCase;
 		eq("FOO", f());
 
 		var a = [];
@@ -332,14 +332,14 @@ class TestPython extends Test {
 	function get_s3() return _s;
 	function set_s3(s) return _s = s;
 
-    function testPropertyInit() {
+	function testPropertyInit() {
 		s += "a";
 		s2 += "b";
 		s3 += "c";
 		eq("nulla", s);
 		eq("nullb", s2);
 		eq("nullc", s3);
-    }
+	}
 
 	function testIsViaParentInterface() {
 		t((new B() is IA));

+ 4 - 4
tests/unit/src/unit/TestSpecification.hx

@@ -127,10 +127,10 @@ class NonRttiClass { }
 @:rtti
 @:keepSub
 class RttiClass1 {
-    static var v:String;
-    public function f() {
-        return 33.0;
-    }
+	static var v:String;
+	public function f() {
+		return 33.0;
+	}
 }
 
 class RttiClass2 extends RttiClass1 { }

+ 55 - 55
tests/unit/src/unit/TestUInt.hx

@@ -6,31 +6,31 @@ class TestUInt extends TestCase
 
   function testFromFloat()
   {
-    inline function floatToInt(float:Float):Int
-    {
-      return cast float;
-    }
-    inline function intToFloat(int:Int):Float
-    {
-      return int;
-    }
-    inline function floatToUInt(float:Float):UInt
-    {
-      return cast float;
-    }
-    inline function uintToInt(uint:UInt):Int
-    {
-      return uint;
-    }
-    inline function uintToFloat(uint:UInt):Float
-    {
-      return uint;
-    }
+	inline function floatToInt(float:Float):Int
+	{
+	  return cast float;
+	}
+	inline function intToFloat(int:Int):Float
+	{
+	  return int;
+	}
+	inline function floatToUInt(float:Float):UInt
+	{
+	  return cast float;
+	}
+	inline function uintToInt(uint:UInt):Int
+	{
+	  return uint;
+	}
+	inline function uintToFloat(uint:UInt):Float
+	{
+	  return uint;
+	}
 
-    assertEquals(-536870912, floatToInt(-536870912.0));
-    assertEquals(-536870912, uintToInt(floatToUInt(-536870912.0)));
-    assertNotEquals(-536870912.0, uintToFloat(floatToUInt( -536870912.0)));
-    assertNotEquals(-536870911.0, floatToUInt(-536870912.0) + 1.0);
+	assertEquals(-536870912, floatToInt(-536870912.0));
+	assertEquals(-536870912, uintToInt(floatToUInt(-536870912.0)));
+	assertNotEquals(-536870912.0, uintToFloat(floatToUInt( -536870912.0)));
+	assertNotEquals(-536870911.0, floatToUInt(-536870912.0) + 1.0);
   }
 
 	function assertNotEquals<T>( expected: T , actual: T,  ?c : haxe.PosInfos ) : Void 	{
@@ -45,53 +45,53 @@ class TestUInt extends TestCase
 
   function testMul()
   {
-    var m:UInt = 0xE0000001;
-    assertEquals(3221225473, m * m);
-    var i:Int = m;
-    assertEquals(-536870911, i);
-    assertEquals(-1073741823, i * m);
-    assertEquals( -1073741823, i * i);
+	var m:UInt = 0xE0000001;
+	assertEquals(3221225473, m * m);
+	var i:Int = m;
+	assertEquals(-536870911, i);
+	assertEquals(-1073741823, i * m);
+	assertEquals( -1073741823, i * i);
   }
 
   function testCompare()
   {
-    var u0:UInt = 0xE0000001;
-    var u1:UInt = 123;
-    assertTrue(u0 > u1);
-    assertTrue(u0 >= u1);
-    assertFalse(u0 < u1);
-    assertFalse(u0 <= u1);
-    var i0:Int = u0;
-    var i1:Int = u1;
-    assertTrue(i0 < i1);
-    assertTrue(i0 <= i1);
-    assertFalse(i0 > i1);
-    assertFalse(i0 >= i1);
+	var u0:UInt = 0xE0000001;
+	var u1:UInt = 123;
+	assertTrue(u0 > u1);
+	assertTrue(u0 >= u1);
+	assertFalse(u0 < u1);
+	assertFalse(u0 <= u1);
+	var i0:Int = u0;
+	var i1:Int = u1;
+	assertTrue(i0 < i1);
+	assertTrue(i0 <= i1);
+	assertFalse(i0 > i1);
+	assertFalse(i0 >= i1);
   }
 
   function testPostfixIncrement()
   {
-    var m:UInt = 0xE0000001;
-    var m0:UInt = 0xE0000001;
-    var m1:UInt = 0xE0000002;
-    assertEquals(m0, m++);
-    assertEquals(m1, m);
+	var m:UInt = 0xE0000001;
+	var m0:UInt = 0xE0000001;
+	var m1:UInt = 0xE0000002;
+	assertEquals(m0, m++);
+	assertEquals(m1, m);
   }
 
   function testPrefixIncrement()
   {
-    var m:UInt = 0xE0000000;
-    var m1:UInt = 0xE0000001;
-    assertEquals(m1, ++m);
-    assertEquals(m1, m);
+	var m:UInt = 0xE0000000;
+	var m1:UInt = 0xE0000001;
+	assertEquals(m1, ++m);
+	assertEquals(m1, m);
   }
 
   function testToInt()
   {
-    var m:UInt = 0xE0000001;
-    var i:Int = m;
-    var f:Float = m;
-    assertTrue(i != f);
+	var m:UInt = 0xE0000001;
+	var i:Int = m;
+	var f:Float = m;
+	assertTrue(i != f);
   }
 
 }

+ 4 - 4
tests/unit/src/unit/TestXML.hx

@@ -198,10 +198,10 @@ class TestXML extends Test {
 	}
 
 	function testIssue3058() {
-        var xml = Xml.createElement("node");
-        xml.set("key", 'a"b\'&c>d<e');
-        eq('a"b\'&c>d<e', xml.get("key"));
-        eq('<node key="a&quot;b&#039;&amp;c&gt;d&lt;e"/>', xml.toString());
+		var xml = Xml.createElement("node");
+		xml.set("key", 'a"b\'&c>d<e');
+		eq('a"b\'&c>d<e', xml.get("key"));
+		eq('<node key="a&quot;b&#039;&amp;c&gt;d&lt;e"/>', xml.toString());
 	}
 
 	function testIssue3630() {

+ 1 - 1
tests/unit/src/unit/hxcpp_issues/Issue189.hx

@@ -3,7 +3,7 @@ package unit.hxcpp_issues;
 
 class Issue189 extends Test {
    dynamic function dynamicWidthDefaults(first=true, second=6, third=10.5) : Float {
-      return first ? second : third;
+	  return first ? second : third;
    }
 	function test() {
 		eq(dynamicWidthDefaults(),6);

+ 8 - 8
tests/unit/src/unit/hxcpp_issues/Issue193.hx.disabled

@@ -15,18 +15,18 @@ class Issue193 extends Test
    inline static function doInc(t:Issue193) t.incField();
 
    macro public static function build ():Array<Field> {
-      var fields = Context.getBuildFields();
-      var newField = macro { 
-        doInc(null);
-      };
-      fields.push ({ name: "genField", access: [ APublic ], kind: FFun({ args: [], expr: newField, params: [], ret: null }), pos: Context.currentPos() });
-      return fields;
+	  var fields = Context.getBuildFields();
+	  var newField = macro {
+		doInc(null);
+	  };
+	  fields.push ({ name: "genField", access: [ APublic ], kind: FFun({ args: [], expr: newField, params: [], ret: null }), pos: Context.currentPos() });
+	  return fields;
    }
 
    function test()
    {
-      var field = Reflect.field(this,"genField");
-      t(field!=null);
+	  var field = Reflect.field(this,"genField");
+	  t(field!=null);
    }
 }
 

+ 4 - 4
tests/unit/src/unit/hxcpp_issues/Issue225.hx

@@ -9,11 +9,11 @@ interface InterfaceWithDefaultI64 {
 
 class Issue225 extends Test implements InterfaceWithDefaultI64 {
 	function test() {
-      var i:InterfaceWithDefaultI64 = new Issue225();
-      eq(i.optionalI64(), -1);
-      eq(i.optionalI64(Int64.make(0,1)), 1);
+	  var i:InterfaceWithDefaultI64 = new Issue225();
+	  eq(i.optionalI64(), -1);
+	  eq(i.optionalI64(Int64.make(0,1)), 1);
    }
    public function optionalI64(?i:Int64)
-       return i==null ? -1 : i.toInt();
+	   return i==null ? -1 : i.toInt();
 }
 

+ 1 - 1
tests/unit/src/unit/hxcpp_issues/String.hx

@@ -5,7 +5,7 @@ class String extends Test {
    @:keep public var y:Float;
    @:keep public function z() return 1;
 	function test() {
-      y = 1.0;
+	  y = 1.0;
 		t( Reflect.hasField(String, "x") );
 		eq( Reflect.field(this, "y"),1.0);
 		eq( Reflect.field(this, "z")(),1);

+ 2 - 2
tests/unit/src/unit/issues/Issue1497.hx

@@ -2,7 +2,7 @@ package unit.issues;
 
 class Issue1497 extends Test {
 	function test() {
-        unit.issues.misc.Issue1497Macro.run();
-        eq(1, Issue1497DefinedClass.test());
+		unit.issues.misc.Issue1497Macro.run();
+		eq(1, Issue1497DefinedClass.test());
 	}
 }

+ 18 - 18
tests/unit/src/unit/issues/Issue1827.hx

@@ -1,18 +1,18 @@
 package unit.issues;
 
 private class C {
-    public var a:Int;
-    public var b:Int;
-
-    public function new() {
-        a = 1;
-        b = 2;
-    }
-
-    public inline function set(inA:Int, inB:Int) {
-        a = inA;
-        b = inB;
-    }
+	public var a:Int;
+	public var b:Int;
+
+	public function new() {
+		a = 1;
+		b = 2;
+	}
+
+	public inline function set(inA:Int, inB:Int) {
+		a = inA;
+		b = inB;
+	}
 }
 
 private class D {
@@ -26,12 +26,12 @@ private class D {
 
 
 class Issue1827 extends Test {
-    //function test() {
-        //var t = new C();
-        //t.set(t.b, t.a);
-        //eq(2, t.a);
-        //eq(1, t.b);
-    //}
+	//function test() {
+		//var t = new C();
+		//t.set(t.b, t.a);
+		//eq(2, t.a);
+		//eq(1, t.b);
+	//}
 
 	static var i = 0;
 

+ 2 - 2
tests/unit/src/unit/issues/Issue1925.hx

@@ -8,12 +8,12 @@ import cs.NativeArray;
 class Issue1925 extends Test {
 #if (java || cs)
 		static var d2:Array<NativeArray<Int>>;
-    function test() {
+	function test() {
 			var d = new NativeArray<Int>(10);
 			d2 = [d];
 			d[0] = 10;
 			eq(d2[0][0], 10);
-    }
+	}
 #end
 }
 

+ 8 - 8
tests/unit/src/unit/issues/Issue1997.hx

@@ -1,12 +1,12 @@
 package unit.issues;
 
 class Issue1997 extends Test {
-    function test() {
-        var arr = [];
-        [1,2,3].map(arr.push);
-        eq(arr.length, 3);
-        eq(arr[0], 1);
-        eq(arr[1], 2);
-        eq(arr[2], 3);
-    }
+	function test() {
+		var arr = [];
+		[1,2,3].map(arr.push);
+		eq(arr.length, 3);
+		eq(arr[0], 1);
+		eq(arr[1], 2);
+		eq(arr[2], 3);
+	}
 }

+ 1 - 1
tests/unit/src/unit/issues/Issue2044.hx

@@ -2,7 +2,7 @@ package unit.issues;
 
 @:generic
 private class Gen<T> {
-    public function new(t:T) { }
+	public function new(t:T) { }
 }
 
 class Issue2044 extends Test {

+ 5 - 5
tests/unit/src/unit/issues/Issue2085.hx

@@ -4,15 +4,15 @@ private class Object extends Node<Object,Ar<Object>> { }
 
 @:generic
 private class Node<T,Array_t:Ar<T>> {
-    public var ar:Array_t;
+	public var ar:Array_t;
 }
 
 @:generic
 private class Ar<T> {
-    public var nongen:Array<T>;
-    public function length():Void {
-        nongen.length;
-    }
+	public var nongen:Array<T>;
+	public function length():Void {
+		nongen.length;
+	}
 }
 
 class Issue2085 extends Test {

+ 21 - 21
tests/unit/src/unit/issues/Issue2130.hx

@@ -1,40 +1,40 @@
 package unit.issues;
 
 private abstract ZeroOneFloat(Float) to Float {
-    public inline function new(v:Float) {
-        this = v<0 ? 0. : (v>1 ? 1. : v);
-    }
+	public inline function new(v:Float) {
+		this = v<0 ? 0. : (v>1 ? 1. : v);
+	}
 
-    @:from public static inline function fromInt(v:Int) {
-        return new ZeroOneFloat(v);
-    }
+	@:from public static inline function fromInt(v:Int) {
+		return new ZeroOneFloat(v);
+	}
 
-    @:from public static inline function fromFloat(v:Float) {
-        return new ZeroOneFloat(v);
-    }
+	@:from public static inline function fromFloat(v:Float) {
+		return new ZeroOneFloat(v);
+	}
 
-    @:op(A *= B) public inline function umul_f(r:Float) : ZeroOneFloat {
-        return this = new ZeroOneFloat(this*r);
-    }
+	@:op(A *= B) public inline function umul_f(r:Float) : ZeroOneFloat {
+		return this = new ZeroOneFloat(this*r);
+	}
 
-    @:op(A * B) @:commutative public static inline function mul_i(l:ZeroOneFloat, r:Float) {
+	@:op(A * B) @:commutative public static inline function mul_i(l:ZeroOneFloat, r:Float) {
 		return (l : Float) * r;
 	}
 }
 
 class Issue2130 extends Test {
 	function test() {
-        var f : ZeroOneFloat = 0.5;
-        feq(0.5, f);
-        f *= 2.;
-        feq(1, f);
+		var f : ZeroOneFloat = 0.5;
+		feq(0.5, f);
+		f *= 2.;
+		feq(1, f);
 
 
-        var f : ZeroOneFloat = 0.5;
-        var a : Float = 10.;
+		var f : ZeroOneFloat = 0.5;
+		var a : Float = 10.;
 		feq(5, a * f);
 
-        a *= f;
-        feq(5, a);
+		a *= f;
+		feq(5, a);
 	}
 }

+ 10 - 10
tests/unit/src/unit/issues/Issue2157.hx

@@ -1,20 +1,20 @@
 package unit.issues;
 
 private abstract Choice<X,Y>(Dynamic) {
-    private function new (x:Dynamic) this = x;
+	private function new (x:Dynamic) this = x;
 
-    @:from public static function fromX <X,Y>(x:X):Choice<X,Y> return new Choice(x);
-    @:from public static function fromY <X,Y>(y:Y):Choice<X,Y> return new Choice(y);
+	@:from public static function fromX <X,Y>(x:X):Choice<X,Y> return new Choice(x);
+	@:from public static function fromY <X,Y>(y:Y):Choice<X,Y> return new Choice(y);
 }
 
 private abstract False(Bool) {
-    inline function new (x:Bool) this = x;
-    @:from public static function fromBool (b:Bool) {
-        if (!b) {
-            throw "assert " + b + " should be false";
-        }
-        return new False(b);
-    }
+	inline function new (x:Bool) this = x;
+	@:from public static function fromBool (b:Bool) {
+		if (!b) {
+			throw "assert " + b + " should be false";
+		}
+		return new False(b);
+	}
 }
 
 

+ 12 - 12
tests/unit/src/unit/issues/Issue2224.hx

@@ -11,20 +11,20 @@ class Issue2224 extends unit.Test {
 		#end
 	}
 
-    static function getEF1( ?opt : Null<haxe.EnumFlags<MyEnum>> ){
-        return( 'opt=$opt' );
-    }
+	static function getEF1( ?opt : Null<haxe.EnumFlags<MyEnum>> ){
+		return( 'opt=$opt' );
+	}
 
-    static function getEF2( ?opt : haxe.EnumFlags<MyEnum> ){
-        return( 'opt=$opt' );
-    }
+	static function getEF2( ?opt : haxe.EnumFlags<MyEnum> ){
+		return( 'opt=$opt' );
+	}
 
-    static function getInt( ?opt : Int ){
-        return( 'opt=$opt' );
-    }
+	static function getInt( ?opt : Int ){
+		return( 'opt=$opt' );
+	}
 
-    static function getClass( ?opt : MyClass ){
-        return( 'opt=$opt' );
-    }
+	static function getClass( ?opt : MyClass ){
+		return( 'opt=$opt' );
+	}
 
 }

+ 5 - 5
tests/unit/src/unit/issues/Issue2235.hx

@@ -2,15 +2,15 @@ package unit.issues;
 import unit.Test;
 
 private abstract A(Int) from Int {
-    function f() {}
-    static function fs() {}
+	function f() {}
+	static function fs() {}
 }
 
 class Issue2235 extends Test {
 	function test() {
-        var a:A = 0;
-        t(unit.TestType.typeError(a.f()));
-        t(unit.TestType.typeError(a.f));
+		var a:A = 0;
+		t(unit.TestType.typeError(a.f()));
+		t(unit.TestType.typeError(a.f));
 		t(unit.TestType.typeError(A.fs()));
 		t(unit.TestType.typeError(A.fs));
 	}

+ 21 - 21
tests/unit/src/unit/issues/Issue2236.hx

@@ -1,33 +1,33 @@
 package unit.issues;
 
 private class ArrayIterator<T> {
-    var a : Array<T>;
-    var pos : Int;
-    public inline function new(a) {
-        this.a = a;
-        this.pos = 0;
-    }
-    public inline function hasNext() {
-        return pos < a.length;
-    }
-    public inline function next() {
-        return a[pos++];
-    }
+	var a : Array<T>;
+	var pos : Int;
+	public inline function new(a) {
+		this.a = a;
+		this.pos = 0;
+	}
+	public inline function hasNext() {
+		return pos < a.length;
+	}
+	public inline function next() {
+		return a[pos++];
+	}
 }
 
 private abstract ArrayRead<T>(Array<T>) {
 
-    public inline function new(a) {
-        this = a;
-    }
+	public inline function new(a) {
+		this = a;
+	}
 
-    function toArray() : Array<T> {
-        return this;
-    }
+	function toArray() : Array<T> {
+		return this;
+	}
 
-    public inline function iterator() : ArrayIterator<T> {
-        return new ArrayIterator(this);
-    }
+	public inline function iterator() : ArrayIterator<T> {
+		return new ArrayIterator(this);
+	}
 
 }
 

+ 2 - 2
tests/unit/src/unit/issues/Issue2281.hx

@@ -2,7 +2,7 @@ package unit.issues;
 
 class Issue2281 extends Test
 {
-    function test() {
+	function test() {
 			var fint = new Foo();
 			fint.val = 0;
 			eq(0, fint.val++);
@@ -19,7 +19,7 @@ class Issue2281 extends Test
 			eq(1,fint.val2);
 			eq(2,++fint.val2);
 			eq(12, fint.val2 += 10);
-    }
+	}
 }
 
 

+ 2 - 2
tests/unit/src/unit/issues/Issue2282.hx

@@ -2,10 +2,10 @@ package unit.issues;
 
 class Issue2282 extends Test
 {
-    function test() {
+	function test() {
 			var f = new Foo();
 			eq(null,f.val);
-    }
+	}
 }
 
 

+ 4 - 4
tests/unit/src/unit/issues/Issue2343.hx

@@ -1,14 +1,14 @@
 package unit.issues;
 
 private abstract MyInt(Int) from Int {
-    public function work() return this;
+	public function work() return this;
 }
 
 private class Foo<T:MyInt> {
 	public var result:Int;
-    public function new(val : T) {
-        result = val.work();
-    }
+	public function new(val : T) {
+		result = val.work();
+	}
 }
 
 class Issue2343 extends unit.Test {

+ 2 - 2
tests/unit/src/unit/issues/Issue2380.hx

@@ -11,6 +11,6 @@ class Issue2380 extends unit.Test
 
 #if !cpp @:nativeGen #end private class SomeCls
 {
-    public function new():Void {}
-    @:keep public function test(v) return v == null;
+	public function new():Void {}
+	@:keep public function test(v) return v == null;
 }

+ 30 - 30
tests/unit/src/unit/issues/Issue2396.hx

@@ -2,55 +2,55 @@ package unit.issues;
 
 private class AA
 {
-    public var x:Float;
-    public var y:Float;
-
-    inline public function new(x:Float, y:Float)
-    {
-        this.x = x;
-        this.y = y;
-    }
+	public var x:Float;
+	public var y:Float;
+
+	inline public function new(x:Float, y:Float)
+	{
+		this.x = x;
+		this.y = y;
+	}
 }
 
 private abstract BB(AA)
 {
-    public var x(get, set):Float;
-    public var y(get, set):Float;
+	public var x(get, set):Float;
+	public var y(get, set):Float;
 
 
-    inline public function get_x():Float return this.x;
-    inline public function get_y():Float return this.y;
+	inline public function get_x():Float return this.x;
+	inline public function get_y():Float return this.y;
 
-    inline public function set_x(v:Float):Float return this.x = v;
-    inline public function set_y(v:Float):Float return this.y = v;
+	inline public function set_x(v:Float):Float return this.x = v;
+	inline public function set_y(v:Float):Float return this.y = v;
 
-    public inline function new(x:Float = 0, y:Float = 0)
-    {
-        this = new AA(x, y);
-    }
+	public inline function new(x:Float = 0, y:Float = 0)
+	{
+		this = new AA(x, y);
+	}
 
-    @:commutative @:op(A*B) inline public static function opMulSF(a:BB, s:Float):BB
-    {
-        return new BB(a.x * s, a.y * s);
-    }
+	@:commutative @:op(A*B) inline public static function opMulSF(a:BB, s:Float):BB
+	{
+		return new BB(a.x * s, a.y * s);
+	}
 }
 
 
 class Issue2396 extends Test {
 	function test() {
-        var a = new BB(10, 20);
+		var a = new BB(10, 20);
 
-        var t1 = 1.0;
-        var t2 = 2.0;
+		var t1 = 1.0;
+		var t2 = 2.0;
 
-        // !!! fails here
-        var fail = a * (t1 + t2);
+		// !!! fails here
+		var fail = a * (t1 + t2);
 		feq(30, fail.x);
 		feq(60, fail.y);
 
-        // ok here
-        var cacheSum = (t1 + t2);
-        var ok = a * cacheSum;
+		// ok here
+		var cacheSum = (t1 + t2);
+		var ok = a * cacheSum;
 		feq(30, ok.x);
 		feq(60, ok.y);
 	}

+ 2 - 2
tests/unit/src/unit/issues/Issue2401.hx

@@ -2,8 +2,8 @@ package unit.issues;
 import unit.Test;
 
 private abstract Foo(Int) from Int {
-    public function toString()
-        return 'Foo: $this';
+	public function toString()
+		return 'Foo: $this';
 }
 
 class Issue2401 extends Test {

+ 2 - 2
tests/unit/src/unit/issues/Issue2409.hx

@@ -1,8 +1,8 @@
 package unit.issues;
 
 private abstract Foo(Int) {
-    public function new(x:Int) this = x;
-    @:op(A+B) public static function add(a:Foo, b:Foo):Foo;
+	public function new(x:Int) this = x;
+	@:op(A+B) public static function add(a:Foo, b:Foo):Foo;
 	public function get() {
 		return this;
 	}

+ 2 - 2
tests/unit/src/unit/issues/Issue2478.hx

@@ -1,7 +1,7 @@
 package unit.issues;
 
 class Issue2478 extends Test {
-    function test() {
+	function test() {
 			var o:Outcome<Int,String> = Success(5);
 
 			switch (o) {
@@ -10,7 +10,7 @@ class Issue2478 extends Test {
 				default:
 					throw "assert";
 			}
-    }
+	}
 }
 
 private enum Outcome<D,F> {

+ 2 - 2
tests/unit/src/unit/issues/Issue2508.hx.disabled

@@ -1,8 +1,8 @@
 package unit.issues;
 
 enum Tree<T> {
-    Leaf(v:T);
-    Node(l:Tree<T>, r:Tree<T>);
+	Leaf(v:T);
+	Node(l:Tree<T>, r:Tree<T>);
 }
 
 class Issue2508 extends unit.Test {

+ 2 - 2
tests/unit/src/unit/issues/Issue2540.hx

@@ -2,12 +2,12 @@ package unit.issues;
 
 class Issue2540 extends Test
 {
-    function test() {
+	function test() {
 			var r = new T();
 			eq(42,r.whatever());
 			var r:Foo<Dynamic> = new T();
 			eq(42,r.whatever());
-    }
+	}
 }
 
 private interface Foo<T>

+ 2 - 2
tests/unit/src/unit/issues/Issue2580.hx

@@ -1,8 +1,8 @@
 package unit.issues;
 
 private enum T {
-    T1(x:Null<T>);
-    T2(x:Int);
+	T1(x:Null<T>);
+	T2(x:Int);
 }
 
 class Issue2580 extends Test {

+ 14 - 14
tests/unit/src/unit/issues/Issue2581.hx

@@ -3,32 +3,32 @@ package unit.issues;
 @:generic
 private interface Arrayable<T>
 {
-    public function toArray(?target:Array<T>):Array<T>;
+	public function toArray(?target:Array<T>):Array<T>;
 }
 
 @:generic
 private class KVPair<K, V>
 {
-    public var key:K;
-    public var value:V;
+	public var key:K;
+	public var value:V;
 
-    public function new():Void
-    {}
+	public function new():Void
+	{}
 }
 
 @:generic
 private class MMap<K, V> implements Arrayable<KVPair<K, V>>
 {
-    public function new():Void
-    {}
+	public function new():Void
+	{}
 
-    public function toArray(?target:Array<KVPair<K, V>>):Array<KVPair<K, V>>
-    {
-        if (target == null) {
-            target = new Array<KVPair<K, V>>();
-        }
-        return target;
-    }
+	public function toArray(?target:Array<KVPair<K, V>>):Array<KVPair<K, V>>
+	{
+		if (target == null) {
+			target = new Array<KVPair<K, V>>();
+		}
+		return target;
+	}
 }
 
 class Issue2581 extends Test {

+ 5 - 5
tests/unit/src/unit/issues/Issue2584.hx

@@ -2,11 +2,11 @@ package unit.issues;
 import haxe.ds.Option;
 
 private abstract X (String) to String {
-    public function new (s:String) this = s;
+	public function new (s:String) this = s;
 }
 
 private abstract XX (String) {
-    public function new (s:String) this = s;
+	public function new (s:String) this = s;
 
 	@:to function toString():String {
 		return cast this;
@@ -18,15 +18,15 @@ private abstract X2(X) to X {}
 private abstract XArr(Array<X>) to Array<X> {}
 
 private class A {
-    public var x : X;
+	public var x : X;
 }
 
 private typedef B = {
-    var x : String;
+	var x : String;
 }
 
 private typedef B1 = {
-    var x(default, null) : String;
+	var x(default, null) : String;
 }
 
 class Issue2584 extends Test {

+ 2 - 2
tests/unit/src/unit/issues/Issue2587.hx

@@ -20,6 +20,6 @@ class Issue2587 extends Test {
 }
 
 private enum E {
-    A;
-    B;
+	A;
+	B;
 }

+ 4 - 4
tests/unit/src/unit/issues/Issue2607.hx

@@ -2,10 +2,10 @@ package unit.issues;
 
 class Issue2607 extends unit.Test {
 
-    inline static var CONST:Float = -1;
+	inline static var CONST:Float = -1;
 
-    function test(v = CONST) {
-        eq(v, -1);
+	function test(v = CONST) {
+		eq(v, -1);
 		t((v is Float));
-    }
+	}
 }

+ 3 - 3
tests/unit/src/unit/issues/Issue2614.hx

@@ -10,8 +10,8 @@ abstract Lazy<T>(Void->T) {
 		return this();
 	}
 
-    @:from static function ofConst<T>(c:T):Lazy<T> {
-        return new Lazy(function() return c);
+	@:from static function ofConst<T>(c:T):Lazy<T> {
+		return new Lazy(function() return c);
 	}
 }
 
@@ -27,6 +27,6 @@ class Issue2614 extends Test {
 	}
 
 	static public function lazy<A>(l:Lazy<A>):Lazy<A> {
-        return l;
+		return l;
 	}
 }

+ 4 - 4
tests/unit/src/unit/issues/Issue2627.hx

@@ -4,12 +4,12 @@ class Issue2627 extends unit.Test {
 
 	var field:Int;
 
-    function test1() {
-        var c = 0;
-        var s = staticAdd(c++, c++);
+	function test1() {
+		var c = 0;
+		var s = staticAdd(c++, c++);
 		eq(s, -1);
 		eq(c, 2);
-    }
+	}
 
 	function test2() {
 		field = 0;

+ 9 - 9
tests/unit/src/unit/issues/Issue2633.hx

@@ -2,24 +2,24 @@ package unit.issues;
 import unit.Test;
 
 @:enum abstract WorldRegion(Int) {
-    static public inline var MiddleCenter = 1;
+	static public inline var MiddleCenter = 1;
 }
 
 class Issue2633 extends Test {
 
 	function test() {
-       eq(1, match(0));
-       eq(1, match(1));
-       eq(2, match(2));
-       eq(2, match(3));
+	   eq(1, match(0));
+	   eq(1, match(1));
+	   eq(2, match(2));
+	   eq(2, match(3));
 	}
 
 	function match(i) {
 		return switch [WorldRegion.MiddleCenter, i] {
-            case [WorldRegion.MiddleCenter, 1]|[WorldRegion.MiddleCenter, 0]:
+			case [WorldRegion.MiddleCenter, 1]|[WorldRegion.MiddleCenter, 0]:
 				1;
-            case _:
-                2;
-        }
+			case _:
+				2;
+		}
 	}
 }

+ 5 - 5
tests/unit/src/unit/issues/Issue2639.hx

@@ -2,14 +2,14 @@ package unit.issues;
 import unit.Test;
 
 typedef Measurable = {
-    public var length(default, null):Int;
+	public var length(default, null):Int;
 }
 
 private abstract A<T>(Int) {
-    public function new(i) this = i;
-    @:from static public inline function fromT<T:Measurable>(t:T) {
-        return new A(t.length);
-    }
+	public function new(i) this = i;
+	@:from static public inline function fromT<T:Measurable>(t:T) {
+		return new A(t.length);
+	}
 
 	public function get() {
 		return this;

+ 3 - 3
tests/unit/src/unit/issues/Issue2653.hx

@@ -14,13 +14,13 @@ private class BasicTexture<R> extends BasicAsset {
 	public function new(i:Int, s:String) {
 		super(s);
 		this.i = i;
-    }
+	}
 }
 
 private class CanvasTexture extends BasicTexture<Int> {
-    public function new(i:Int, s:String) {
+	public function new(i:Int, s:String) {
 		super(i, s);
-    }
+	}
 }
 
 class Issue2653 extends Test {

+ 10 - 10
tests/unit/src/unit/issues/Issue2664.hx

@@ -3,19 +3,19 @@ import unit.Test;
 
 class Issue2664 extends Test {
 
-    function test() {
-        var i = 0;
+	function test() {
+		var i = 0;
 		var buf = "";
-        eq(-2,sub({buf += "a" + i; i++; },toABase({ buf += "b" + i; i++;})));
+		eq(-2,sub({buf += "a" + i; i++; },toABase({ buf += "b" + i; i++;})));
 		eq("a0b1", buf.toString());
 		eq(2, i);
-    }
+	}
 
-    static function sub(a, b) {
-        return a - b;
-    }
+	static function sub(a, b) {
+		return a - b;
+	}
 
-    static function toABase(i) {
-        return i * 2;
-    }
+	static function toABase(i) {
+		return i * 2;
+	}
 }

+ 2 - 2
tests/unit/src/unit/issues/Issue2668.hx.disabled

@@ -1,7 +1,7 @@
 package unit.issues;
 
 class Issue2688 extends Test {
-    function test() {
+	function test() {
 			var called = false;
 			function isCalled() {
 				called = true;
@@ -9,7 +9,7 @@ class Issue2688 extends Test {
 			var child = new Child(test);
 			child.task([1,2,3,4]);
 			t(called);
-    }
+	}
 }
 
 @:nativeGen private class NativeGen

+ 2 - 2
tests/unit/src/unit/issues/Issue2685.hx

@@ -2,8 +2,8 @@ package unit.issues;
 import unit.Test;
 
 private abstract A({a:Int}) from {a:Int} {
-    @:to function toInt():Int return this.a * 4;
-    @:to function toDynamic():Dynamic return this.a * 2;
+	@:to function toInt():Int return this.a * 4;
+	@:to function toDynamic():Dynamic return this.a * 2;
 }
 
 class Issue2685 extends Test {

+ 4 - 4
tests/unit/src/unit/issues/Issue2696.hx

@@ -3,11 +3,11 @@ import unit.Test;
 
 
 class Issue2696 extends Test {
-    private static var value = 2;
+	private static var value = 2;
 
-    inline private static function func() :Int {
-        return -value;
-    }
+	inline private static function func() :Int {
+		return -value;
+	}
 
 	function test() {
 		eq(2, -func());

+ 6 - 6
tests/unit/src/unit/issues/Issue2698.hx

@@ -2,8 +2,8 @@ package unit.issues;
 import unit.Test;
 
 private abstract IntString(String) {
-    @:from static function fromInt(i:Int):IntString return cast Std.string(i);
-    @:to function toInt():Int return Std.parseInt(this);
+	@:from static function fromInt(i:Int):IntString return cast Std.string(i);
+	@:to function toInt():Int return Std.parseInt(this);
 }
 
 class Issue2698 extends Test {
@@ -12,22 +12,22 @@ class Issue2698 extends Test {
 		var b:Int = 1;
 		var c:IntString = 2;
 		var d:Int = 2;
-		
+
 		t(a == a);
 		t(a == b);
 		f(a == c);
 		f(a == d);
-		
+
 		t(b == a);
 		t(b == b);
 		f(b == c);
 		f(b == d);
-		
+
 		f(c == a);
 		f(c == b);
 		t(c == c);
 		t(c == d);
-		
+
 		f(d == a);
 		f(d == b);
 		t(d == c);

+ 5 - 5
tests/unit/src/unit/issues/Issue2712.hx

@@ -4,17 +4,17 @@ import unit.Test;
 class Item implements Heapable {}
 
 interface Collection<T> {
-    function contains(x:T):Bool;
+	function contains(x:T):Bool;
 }
 
 interface Heapable {}
 
 class Heap<T:(Heapable)> implements Collection<T> {
-    public function new() {}
+	public function new() {}
 
-    public function contains(x:T):Bool {
-        return true;
-    }
+	public function contains(x:T):Bool {
+		return true;
+	}
 }
 
 class Issue2712 extends Test {

+ 3 - 3
tests/unit/src/unit/issues/Issue2735.hx

@@ -3,8 +3,8 @@ import unit.Test;
 
 class Issue2735 extends Test {
 	function test() {
-        var uint:UInt = 0xFFFFFFFF;
-        var f:Float = uint;
-        feq(4294967295., f);
+		var uint:UInt = 0xFFFFFFFF;
+		var f:Float = uint;
+		feq(4294967295., f);
 	}
 }

+ 15 - 15
tests/unit/src/unit/issues/Issue2736.hx

@@ -4,28 +4,28 @@ import unit.Test;
 /** UInt not showing proper unsigned behavior */
 class Issue2736 extends Test {
 	function test() {
-        var a:UInt, b:UInt;
+		var a:UInt, b:UInt;
 
-        b = 50000;
-        a = b * b;
+		b = 50000;
+		a = b * b;
 
-        eq( a, b*b );
-        eq( a/b, 50000 );
-        eq(a % b, 0);
+		eq( a, b*b );
+		eq( a/b, 50000 );
+		eq(a % b, 0);
 
-        f(a == b); t(a != b);
-        t(a > b); t(a >= b);
-        f(a < b); f(a <= b);
+		f(a == b); t(a != b);
+		t(a > b); t(a >= b);
+		f(a < b); f(a <= b);
 
-        // UInt vs Float comparisons
-        f( a == 1.0 ); t( b == 50000.0 );
-        t( a > 1.0 ); t( a >= 1.0 );
-        f( a < -1.0 ); f( a <= 1.0 );
+		// UInt vs Float comparisons
+		f( a == 1.0 ); t( b == 50000.0 );
+		t( a > 1.0 ); t( a >= 1.0 );
+		f( a < -1.0 ); f( a <= 1.0 );
 
 		#if false // ?
 		var u:UInt = 2147483648;
-        eq(1073741824, u >> 1);
-        eq(1073741824, u >>> 1);
+		eq(1073741824, u >> 1);
+		eq(1073741824, u >>> 1);
 		#end
 	}
 }

+ 8 - 8
tests/unit/src/unit/issues/Issue2750.hx

@@ -2,10 +2,10 @@ package unit.issues;
 import unit.Test;
 
 private class Parent extends Test {
-    function new() {
+	function new() {
 		super();
 	}
-	
+
 	function foo() {
 		return 1;
 	}
@@ -21,9 +21,9 @@ class Issue2750 extends Parent {
 	function test() {
 		new Issue2750();
 	}
-	
-    public function new() {
-        super();
+
+	public function new() {
+		super();
 		eq(3, foo());
 		eq(3, bind());
 		eq(3, match());
@@ -32,8 +32,8 @@ class Issue2750 extends Parent {
 		t(unit.TestType.typeError(call(super)));
 		t(unit.TestType.typeError({ field: super }));
 		t(unit.TestType.typeError([super]));
-    }
-	
+	}
+
 	override function foo() {
 		return 2 + super.foo();
 	}
@@ -45,6 +45,6 @@ class Issue2750 extends Parent {
 	override function match() {
 		return 2 + super.match();
 	}
-	
+
 	function call(c:Parent) { }
 }

+ 1 - 1
tests/unit/src/unit/issues/Issue2763.hx

@@ -16,7 +16,7 @@ class Issue2763 extends Test {
 			acc += ";" + i;
 		} while (call(i++) < call2(i++));
 		eq(";0;2;4", acc);
-    }
+	}
 
 	static function call(i:Int) {
 		return i;

+ 6 - 6
tests/unit/src/unit/issues/Issue2766.hx

@@ -2,8 +2,8 @@ package unit.issues;
 import unit.Test;
 
 private class Foo {
-    public var foo = "foo";
-    public function new () {}
+	public var foo = "foo";
+	public function new () {}
 }
 
 class Issue2766 extends Test {
@@ -11,8 +11,8 @@ class Issue2766 extends Test {
 	function test() {
 		eq("foo", getValue());
 	}
-	
-    macro static function getValue() {
-        return macro $v{new Foo().foo};
-    }
+
+	macro static function getValue() {
+		return macro $v{new Foo().foo};
+	}
 }

+ 8 - 8
tests/unit/src/unit/issues/Issue2778.hx

@@ -1,8 +1,8 @@
 package unit.issues;
 
 enum E<T> {
-    BoolLit(b:Bool):E<Bool>;
-    IntLit(i:Int):E<Int>;
+	BoolLit(b:Bool):E<Bool>;
+	IntLit(i:Int):E<Int>;
 }
 
 class Issue2778 extends Test {
@@ -17,10 +17,10 @@ class Issue2778 extends Test {
 		t(unit.TestType.typeError(sameType(BoolLit(true), IntLit(1))));
 	}
 
-    static function sameType<S>(o1:E<S>, o2:E<S>):S {
-        return switch [o1, o2] {
-            case [BoolLit(b1), BoolLit(b2)]: b1 && b2;
-            case [IntLit(i1), IntLit(i2)]: i1 + i2;
-        }
-    }
+	static function sameType<S>(o1:E<S>, o2:E<S>):S {
+		return switch [o1, o2] {
+			case [BoolLit(b1), BoolLit(b2)]: b1 && b2;
+			case [IntLit(i1), IntLit(i2)]: i1 + i2;
+		}
+	}
 }

+ 11 - 11
tests/unit/src/unit/issues/Issue2786.hx

@@ -2,25 +2,25 @@ package unit.issues;
 
 @:enum
 private abstract E(Int) to Int {
-    var A = 1;
-    var B = 2;
-    @:op(a | b) static function or(a:E, b:E):E;
+	var A = 1;
+	var B = 2;
+	@:op(a | b) static function or(a:E, b:E):E;
 }
 
 @:enum
 private abstract E2(Int) to Int {
-    var A = 1;
-    var B = 2;
-    @:op(a | b) static function or(a:E2, b:E2):E2;
-    @:op(a | b) static function or2(a:E2, b:E2):E2;
+	var A = 1;
+	var B = 2;
+	@:op(a | b) static function or(a:E2, b:E2):E2;
+	@:op(a | b) static function or2(a:E2, b:E2):E2;
 }
 
 @:enum
 private abstract E3(Int) to Int {
-    var A = 1;
-    var B = 2;
-    @:op(a | b) static function or(a:E3, b:E3):E3;
-    @:op(a | b) static function or2(a:E3, b:E3):E3;
+	var A = 1;
+	var B = 2;
+	@:op(a | b) static function or(a:E3, b:E3):E3;
+	@:op(a | b) static function or2(a:E3, b:E3):E3;
 }
 
 class Issue2786 extends Test {

+ 25 - 25
tests/unit/src/unit/issues/Issue2792.hx

@@ -2,44 +2,44 @@ package unit.issues;
 import unit.Test;
 
 private class Obj {
-    public var w:Float;
-    public var h:Float;
-    public function new(w:Float = 0, h:Float = 0) {
-        this.w = w;
-        this.h = h;
-    }
+	public var w:Float;
+	public var h:Float;
+	public function new(w:Float = 0, h:Float = 0) {
+		this.w = w;
+		this.h = h;
+	}
 }
 
 private class Node {
-    public var obj:Obj;
+	public var obj:Obj;
 
-    public function new() { }
+	public function new() { }
 
-    public inline function canPlace(w:Float, h:Float):Bool {
-        return (obj.w == w && obj.h == h);
-    }
+	public inline function canPlace(w:Float, h:Float):Bool {
+		return (obj.w == w && obj.h == h);
+	}
 }
 
 
 private class Root {
-    public var left:Node;
-    public var right:Node;
+	public var left:Node;
+	public var right:Node;
 
-    public function new() {}
+	public function new() {}
 }
 
 class Issue2792 extends Test {
 	function test() {
-        var root:Root = new Root();
-        root.left = new Node();
-        root.left.obj = new Obj();
-        var check1:Bool = (root.right != null && root.right.canPlace(0, 0)) && (root.left != null && root.left.canPlace(0, 0));
-        eq(false, check1);
-        var check2:Bool = (root.left != null && root.left.canPlace(0, 0)) && (root.right != null && root.right.canPlace(0, 0));
-        eq(false, check2);
-        var right:Bool = (root.right != null && root.right.canPlace(0, 0));
-        var left:Bool = (root.left != null && root.left.canPlace(0, 0));
-        var both:Bool = right && left;
-        eq(false, both);
+		var root:Root = new Root();
+		root.left = new Node();
+		root.left.obj = new Obj();
+		var check1:Bool = (root.right != null && root.right.canPlace(0, 0)) && (root.left != null && root.left.canPlace(0, 0));
+		eq(false, check1);
+		var check2:Bool = (root.left != null && root.left.canPlace(0, 0)) && (root.right != null && root.right.canPlace(0, 0));
+		eq(false, check2);
+		var right:Bool = (root.right != null && root.right.canPlace(0, 0));
+		var left:Bool = (root.left != null && root.left.canPlace(0, 0));
+		var both:Bool = right && left;
+		eq(false, both);
 	}
 }

+ 13 - 13
tests/unit/src/unit/issues/Issue2810.hx

@@ -2,23 +2,23 @@ package unit.issues;
 import unit.Test;
 
 private abstract A(Array<Int>) {
-    public inline function new(a) {
-        this = a;
-    }
-    @:arrayAccess inline function read(i) {
-        return this[i];
-    }
-    @:arrayAccess inline function write(i,v) {
-        return this[i] = v;
-    }
+	public inline function new(a) {
+		this = a;
+	}
+	@:arrayAccess inline function read(i) {
+		return this[i];
+	}
+	@:arrayAccess inline function write(i,v) {
+		return this[i] = v;
+	}
 }
 
 class Issue2810 extends Test {
 	function test() {
-        var a = new A([5]);
-        var x = a[0];
-        a[0] = 6;
-        a[0] += 3;
+		var a = new A([5]);
+		var x = a[0];
+		a[0] = 6;
+		a[0] += 3;
 		eq(9, a[0]);
 	}
 }

+ 10 - 10
tests/unit/src/unit/issues/Issue2859.hx

@@ -1,20 +1,20 @@
 package unit.issues;
 
 private abstract Error(String) {
-    public function new(message:String) {
-        this = message;
-    }
+	public function new(message:String) {
+		this = message;
+	}
 }
 
 class Issue2859 extends Test {
 	function test() {
-        try {
-            throw new Error("hello");
-        } catch (e:Error) {
+		try {
+			throw new Error("hello");
+		} catch (e:Error) {
 			unit.TestType.typedAs(e, (null:Error));
-            func(e);
-        }
-    }
+			func(e);
+		}
+	}
 
-    static function func(e:Error) { }
+	static function func(e:Error) { }
 }

+ 3 - 3
tests/unit/src/unit/issues/Issue2871.hx

@@ -1,9 +1,9 @@
 package unit.issues;
 
 class Issue2871 extends Test {
-    function call(myUInt:Null<UInt> = null):Int {
-        return myUInt == null ? 0 : myUInt;
-    }
+	function call(myUInt:Null<UInt> = null):Int {
+		return myUInt == null ? 0 : myUInt;
+	}
 
 	function test() {
 		eq(0, call(null));

+ 3 - 3
tests/unit/src/unit/issues/Issue2902.hx

@@ -6,10 +6,10 @@ private class G<T> {
 	public function new(t:T) {
 		this.t = t;
 	}
-    public function f(){
-        haxe.Log;
+	public function f(){
+		haxe.Log;
 		return t;
-    }
+	}
 }
 
 private class G2 extends G<String> { }

+ 19 - 19
tests/unit/src/unit/issues/Issue2951.hx

@@ -14,32 +14,32 @@ class Issue2951 extends Test{
   }
 
   public static function getLast(x:Dynamic) {
-    return true;
+	return true;
   }
 
   public static function exists(x:Dynamic) {
-    return true;
+	return true;
   }
 
   public function test ()
   {
 
-      var last = null;
-      var args = [];
-      var HxString = {
-        charCodeAt : function (a:Array<Dynamic>, i:Int) {
-          return 1;
-        }
-      };
-      if ((if ((if ((exists(last)))getLast(last) else false)){
-          if ((! (args.length < 2))){
-              var _g = HxString.charCodeAt(args[args.length - 2],0);
-              var _g1 = 45;
-              _g != _g1;
-          } else true;
-      } else false)){
-          if ((args.length == 0)) true else false;
-          setCwd(last);
-      };
+	  var last = null;
+	  var args = [];
+	  var HxString = {
+		charCodeAt : function (a:Array<Dynamic>, i:Int) {
+		  return 1;
+		}
+	  };
+	  if ((if ((if ((exists(last)))getLast(last) else false)){
+		  if ((! (args.length < 2))){
+			  var _g = HxString.charCodeAt(args[args.length - 2],0);
+			  var _g1 = 45;
+			  _g != _g1;
+		  } else true;
+	  } else false)){
+		  if ((args.length == 0)) true else false;
+		  setCwd(last);
+	  };
   }
 }

+ 12 - 12
tests/unit/src/unit/issues/Issue2958.hx

@@ -3,17 +3,17 @@ package unit.issues;
 private typedef Asset<@:const T> = String;
 
 class Issue2958 extends Test {
-    function test() {
-        eq(
-           typeString((null : Asset<["test", 1]>)),
-           "unit.issues._Issue2958.Asset<[\"test\", 1]>"
-        );
-    }
+	function test() {
+		eq(
+		   typeString((null : Asset<["test", 1]>)),
+		   "unit.issues._Issue2958.Asset<[\"test\", 1]>"
+		);
+	}
 
-    static macro function typeString(e)
-    {
-        var typed = haxe.macro.Context.typeExpr(e);
-        var s = haxe.macro.TypeTools.toString(typed.t);
-        return macro $v{s};
-    }
+	static macro function typeString(e)
+	{
+		var typed = haxe.macro.Context.typeExpr(e);
+		var s = haxe.macro.TypeTools.toString(typed.t);
+		return macro $v{s};
+	}
 }

+ 2 - 2
tests/unit/src/unit/issues/Issue2963.hx

@@ -17,6 +17,6 @@ class Issue2963 extends Test {
 }
 
 private abstract A<T>(Dynamic<Null<T>>) from Dynamic<Null<T>> {
-    public inline function new() this = {}
-    public inline function get(k:String):Null<T> return Reflect.field(this, k);
+	public inline function new() this = {}
+	public inline function get(k:String):Null<T> return Reflect.field(this, k);
 }

+ 4 - 4
tests/unit/src/unit/issues/Issue2979.hx

@@ -3,14 +3,14 @@ package unit.issues;
 private class A<T> {}
 
 private abstract B<T>(T) {
-    public function toA():A<T> return null;
-    public function a() return toA();
+	public function toA():A<T> return null;
+	public function a() return toA();
 }
 
 class Issue2979 extends Test {
 	function test() {
-        var b:B<String> = null;
-        var a:A<String>;
+		var b:B<String> = null;
+		var a:A<String>;
 		unit.TestType.typedAs(a, b.a());
 		unit.TestType.typedAs(a, b.toA());
 	}

+ 1 - 1
tests/unit/src/unit/issues/Issue2980.hx

@@ -4,7 +4,7 @@ class Issue2980 extends Test {
 
 	#if python
 	function a(?args:python.KwArgs<Dynamic>) {}
-    function b(?args:python.VarArgs<Dynamic>) {}
+	function b(?args:python.VarArgs<Dynamic>) {}
 
 	function test() {
 		a();

+ 5 - 5
tests/unit/src/unit/issues/Issue2982.hx

@@ -6,10 +6,10 @@ class Issue2982 extends Test {
 		eq(12, run());
 	}
 
-    static macro function run() {
-        var map:Map<String,Int> = new Map();
+	static macro function run() {
+		var map:Map<String,Int> = new Map();
 		map["foo"] = 12;
-        var sMap:haxe.ds.StringMap<Int> = map; // Test.hx:8: characters 2-40 : Map<String, Int> should be haxe.ds.StringMap<Int>
-        return macro $v{sMap.get("foo")};
-    }
+		var sMap:haxe.ds.StringMap<Int> = map; // Test.hx:8: characters 2-40 : Map<String, Int> should be haxe.ds.StringMap<Int>
+		return macro $v{sMap.get("foo")};
+	}
 }

+ 7 - 7
tests/unit/src/unit/issues/Issue2988.hx

@@ -1,18 +1,18 @@
 package unit.issues;
 
 private enum MyEnum2 {
-    MyEnumValue(p:String);
+	MyEnumValue(p:String);
 }
 
 class Issue2988 extends Test {
 	function test() {
-        var a : Dynamic = MyEnumValue("foo");
+		var a : Dynamic = MyEnumValue("foo");
 		var s = "";
-        if( (a is MyEnum2) ){
-            switch( a ){
-                case MyEnumValue(s1): s = s1;
-            }
-        }
+		if( (a is MyEnum2) ){
+			switch( a ){
+				case MyEnumValue(s1): s = s1;
+			}
+		}
 		eq("foo", s);
 	}
 }

+ 4 - 4
tests/unit/src/unit/issues/Issue3005.hx

@@ -2,8 +2,8 @@ package unit.issues;
 
 @:generic
 private class A<T> {
-    public function new() {}
-    private function foo() {
+	public function new() {}
+	private function foo() {
 		var b = new B<String>();
 		b.foo();
 	}
@@ -19,7 +19,7 @@ private class B<T> {
 class Issue3005 extends Test {
 	@:access(unit.issues.A)
 	function test() {
-        var a = new A<String>();
-        a.foo();
+		var a = new A<String>();
+		a.foo();
 	}
 }

+ 1 - 1
tests/unit/src/unit/issues/Issue3008.hx

@@ -3,6 +3,6 @@ package unit.issues;
 class Issue3008 extends Test {
 	function test() {
 		var t = new unit.issues.misc.Issue3008Class("foo");
-        t.call();
+		t.call();
 	}
 }

+ 1 - 1
tests/unit/src/unit/issues/Issue3023.hx

@@ -1,7 +1,7 @@
 package unit.issues;
 
 class Issue3023 extends Test {
-    function test() {
+	function test() {
 			var x:Array<Null<Map<Int,CTest>>> = [];
 			x.push([ 0 => new CTest() ]);
 			eq(x[0].get(0).x, 10);

+ 2 - 2
tests/unit/src/unit/issues/Issue3029.hx

@@ -4,8 +4,8 @@ private abstract TemplateData({}) from {} to {} { }
 
 class Issue3029 extends Test {
 	function test() {
-        var t1:TemplateData = {};
-        var t2:TemplateData = { name: "jason" };
+		var t1:TemplateData = {};
+		var t2:TemplateData = { name: "jason" };
 		eq("jason", Reflect.field(t2,"name"));
 	}
 }

+ 5 - 5
tests/unit/src/unit/issues/Issue3033.hx.disabled

@@ -11,15 +11,15 @@ class Issue3033 extends Test
 
 	public static function guessReturnType<T>()
 	{
-    var result = new Ref();
-    function tt(r:Ref<T>):T return dynamicReturnType();
-    if (Math.random() < 0.5) result.t = tt(new Ref<T>());
-    return result;
+	var result = new Ref();
+	function tt(r:Ref<T>):T return dynamicReturnType();
+	if (Math.random() < 0.5) result.t = tt(new Ref<T>());
+	return result;
 	}
 
   public static function dynamicReturnType():Dynamic
   {
-    return guessReturnType();
+	return guessReturnType();
   }
 }
 

+ 4 - 4
tests/unit/src/unit/issues/Issue3042.hx

@@ -1,12 +1,12 @@
 package unit.issues;
 
 private abstract MyAbstract(Int) {
-    public var inlineProp(get, set):Int;
+	public var inlineProp(get, set):Int;
 
-    public function new() {this = 0;}
+	public function new() {this = 0;}
 
-    private inline function get_inlineProp():Int {return this;}
-    private inline function set_inlineProp(value:Int):Int {return this = value;}
+	private inline function get_inlineProp():Int {return this;}
+	private inline function set_inlineProp(value:Int):Int {return this = value;}
 }
 
 class Issue3042 extends Test {

+ 2 - 2
tests/unit/src/unit/issues/Issue3061.hx

@@ -1,11 +1,11 @@
 package unit.issues;
 
 private enum MyEnum1 {
-    A;
+	A;
 }
 
 private enum MyEnum2 {
-    A;
+	A;
 	B;
 }
 

+ 2 - 2
tests/unit/src/unit/issues/Issue3063.hx

@@ -2,12 +2,12 @@ package unit.issues;
 
 @:enum
 private abstract AString(String) to String {
-    var CTOR1 = "foo";
+	var CTOR1 = "foo";
 }
 
 @:enum
 private abstract AInt(Int) to Int {
-    var CTOR2 = 12;
+	var CTOR2 = 12;
 }
 
 class Issue3063 extends Test {

+ 48 - 48
tests/unit/src/unit/issues/Issue3071.hx

@@ -4,53 +4,53 @@ import unit.Test;
 class Issue3071 extends Test {
 
 
-    function test() {
-    	// join
-    	var a : { function join (s:String):String; } = [1,2];
-    	eq("1,2", a.join(","));
-
-    	var a : Dynamic = [1,2];
-    	eq("1,2", a.join(","));
-
-    	// pop
-    	var a : { function pop ():Int; } = [1,2];
-    	a.pop();
-    	var a : Array<Int> = cast a;
-    	eq(1, a.length);
-    	eq(a[0], 1);
-
-    	var a : Dynamic = [1,2];
-    	a.pop();
-    	var a : Array<Int> = cast a;
-    	eq(1, a.length);
-    	eq(a[0], 1);
-
-    	// push
-    	var a : { function push (x:Int):Int; } = [];
-    	a.push(1);
-    	var a : Array<Int> = cast a;
-    	eq(1, a.length);
-    	eq(a[0], 1);
-
-    	var a : Dynamic = [];
-    	a.push(1);
-    	var a : Array<Int> = cast a;
-    	eq(1, a.length);
-    	eq(a[0], 1);
-
-    	// shift
-    	var a : { function shift ():Int; } = [1,2];
-    	a.shift();
-    	var a : Array<Int> = cast a;
-    	eq(1, a.length);
-    	eq(a[0], 2);
-
-    	var a : Dynamic = [1,2];
-    	a.shift();
-    	var a : Array<Int> = cast a;
-    	eq(1, a.length);
-    	eq(a[0], 2);
-
-    }
+	function test() {
+		// join
+		var a : { function join (s:String):String; } = [1,2];
+		eq("1,2", a.join(","));
+
+		var a : Dynamic = [1,2];
+		eq("1,2", a.join(","));
+
+		// pop
+		var a : { function pop ():Int; } = [1,2];
+		a.pop();
+		var a : Array<Int> = cast a;
+		eq(1, a.length);
+		eq(a[0], 1);
+
+		var a : Dynamic = [1,2];
+		a.pop();
+		var a : Array<Int> = cast a;
+		eq(1, a.length);
+		eq(a[0], 1);
+
+		// push
+		var a : { function push (x:Int):Int; } = [];
+		a.push(1);
+		var a : Array<Int> = cast a;
+		eq(1, a.length);
+		eq(a[0], 1);
+
+		var a : Dynamic = [];
+		a.push(1);
+		var a : Array<Int> = cast a;
+		eq(1, a.length);
+		eq(a[0], 1);
+
+		// shift
+		var a : { function shift ():Int; } = [1,2];
+		a.shift();
+		var a : Array<Int> = cast a;
+		eq(1, a.length);
+		eq(a[0], 2);
+
+		var a : Dynamic = [1,2];
+		a.shift();
+		var a : Array<Int> = cast a;
+		eq(1, a.length);
+		eq(a[0], 2);
+
+	}
 
 }

+ 5 - 5
tests/unit/src/unit/issues/Issue3081.hx

@@ -1,17 +1,17 @@
 package unit.issues;
 
 private typedef T1<T> = {
-    function foo():T;
+	function foo():T;
 }
 
 private typedef T2 = {
-    function foo():String;
+	function foo():String;
 }
 
 private typedef T3 = {
-    > T1<String>,
-    > T2,
-    function bar():Int;
+	> T1<String>,
+	> T2,
+	function bar():Int;
 	function foo():String;
 }
 

+ 60 - 60
tests/unit/src/unit/issues/Issue3088.hx

@@ -19,33 +19,33 @@ private class C {
 }
 
 private typedef PublicationData = {
-    year:Int,
-    artist:String,
-    name:String,
-    type:String,
-    ?tracks:Array<String>,
-    ?bSide:String
+	year:Int,
+	artist:String,
+	name:String,
+	type:String,
+	?tracks:Array<String>,
+	?bSide:String
 }
 
 private abstract Publication(PublicationData) from PublicationData {
-    public var year(get, never):Int;
-    public var artist(get, never):String;
-    public var name(get, never):String;
-    public var kind(get, never):PublicationKind;
-    inline function get_year() return this.year;
-    inline function get_artist() return this.artist;
-    inline function get_name() return this.name;
-    inline function get_kind()
-    	return
-            if (this.type == 'album')
-                Album(this.tracks);
-    		else
-                Single(this.bSide);
+	public var year(get, never):Int;
+	public var artist(get, never):String;
+	public var name(get, never):String;
+	public var kind(get, never):PublicationKind;
+	inline function get_year() return this.year;
+	inline function get_artist() return this.artist;
+	inline function get_name() return this.name;
+	inline function get_kind()
+		return
+			if (this.type == 'album')
+				Album(this.tracks);
+			else
+				Single(this.bSide);
 }
 
 private enum PublicationKind {
-    Album(tracks:Array<String>);
-    Single(bSide:String);
+	Album(tracks:Array<String>);
+	Single(bSide:String);
 }
 
 class Issue3088 extends Test {
@@ -54,45 +54,45 @@ class Issue3088 extends Test {
 	}
 
 	function testCrazyJuraj() {
-        var publications:Array<Publication> = [
-            {
-                year : 1967,
-                artist : "The Jimi Hendrix Experience",
-                name : "Are You Experienced?",
-                type : "album",
-                tracks : [/* ... */],
-            },
-            {
-                year : 1978,
-                artist : "Bob Marley and the Wailers",
-                name : "Babylon by Bus",
-                type : "album",
-                tracks : [/* ... */],
-            },
-            {
-                year : 1962,
-                artist : "John Lee Hooker",
-                name : "Boom Boom",
-                type : "single",
-                bSide : "Drug Store Woman",
-            },
-        ];
-        var albumsBefore1970 = [];
-     	for (p in publications)
-            switch p {
-                case {
-             		year : _ < 1970 => true,
-             		name : name,
-             		kind : kind = Album(tracks)
-            	}:
-                    albumsBefore1970.push({
-                        name : name,
-                        kind : kind
-                    });
-                default:
-            }
+		var publications:Array<Publication> = [
+			{
+				year : 1967,
+				artist : "The Jimi Hendrix Experience",
+				name : "Are You Experienced?",
+				type : "album",
+				tracks : [/* ... */],
+			},
+			{
+				year : 1978,
+				artist : "Bob Marley and the Wailers",
+				name : "Babylon by Bus",
+				type : "album",
+				tracks : [/* ... */],
+			},
+			{
+				year : 1962,
+				artist : "John Lee Hooker",
+				name : "Boom Boom",
+				type : "single",
+				bSide : "Drug Store Woman",
+			},
+		];
+		var albumsBefore1970 = [];
+	 	for (p in publications)
+			switch p {
+				case {
+			 		year : _ < 1970 => true,
+			 		name : name,
+			 		kind : kind = Album(tracks)
+				}:
+					albumsBefore1970.push({
+						name : name,
+						kind : kind
+					});
+				default:
+			}
 
-    	eq(1, albumsBefore1970.length);
-    	eq("Are You Experienced?", albumsBefore1970[0].name);
+		eq(1, albumsBefore1970.length);
+		eq("Are You Experienced?", albumsBefore1970[0].name);
 	}
 }

+ 1 - 1
tests/unit/src/unit/issues/Issue3090.hx

@@ -2,7 +2,7 @@ package unit.issues;
 import haxe.xml.Printer;
 @:generic
 private class A<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15>{
-    public function new(){}
+	public function new(){}
 }
 
 class Issue3090 extends Test {

+ 5 - 5
tests/unit/src/unit/issues/Issue3113.hx

@@ -9,9 +9,9 @@ class Issue3113 extends Test
 
 		t = cast B;
 		eq( t.func(1, 2), 1 ); // runtime: Unhandled Exception:
-		                       // Haxe Exception: Method 'func' not found on type B
-		                       // [ERROR] FATAL UNHANDLED EXCEPTION: Haxe Exception: Method 'func' not found on type B
-		                       // -> because of B having type parameter
+							   // Haxe Exception: Method 'func' not found on type B
+							   // [ERROR] FATAL UNHANDLED EXCEPTION: Haxe Exception: Method 'func' not found on type B
+							   // -> because of B having type parameter
 	}
 }
 
@@ -20,10 +20,10 @@ private class Base<T> {}
 
 @:keep private class A
 {
-    public static function func<G>(x:G, y:G):G { return x; }
+	public static function func<G>(x:G, y:G):G { return x; }
 }
 
 @:keep private class B<T> extends Base<T>
 {
-    public static function func<G>(x:G, y:G):G { return x; }
+	public static function func<G>(x:G, y:G):G { return x; }
 }

+ 7 - 7
tests/unit/src/unit/issues/Issue3115.hx

@@ -2,13 +2,13 @@ package unit.issues;
 
 class Issue3115 extends Test {
 	function test() {
-        var k = 0;
-        var i = 0;
-        do {
-            i++;
-            if (i & 1 == 0) continue;
-            k++;
-        } while (i++ < 10);
+		var k = 0;
+		var i = 0;
+		do {
+			i++;
+			if (i & 1 == 0) continue;
+			k++;
+		} while (i++ < 10);
 		eq(12, i);
 		eq(6, k);
 	}

+ 5 - 5
tests/unit/src/unit/issues/Issue3133.hx

@@ -1,14 +1,14 @@
 package unit.issues;
 
 private class Child extends unit.issues.misc.Issue3133Class {
-    override function test(unit:String) {
-        super.test(unit);
-    }
+	override function test(unit:String) {
+		super.test(unit);
+	}
 }
 
 class Issue3133 extends Test {
 	function test() {
-        var t = new Child();
-        t.test("foo");
+		var t = new Child();
+		t.test("foo");
 	}
 }

+ 8 - 8
tests/unit/src/unit/issues/Issue3138.hx

@@ -12,25 +12,25 @@ class Issue3138 extends Test
 }
 
 private class A {
-    public function new(a) {}
+	public function new(a) {}
 }
 
 private class B extends A {
-    public function new(?a = 1) {
-        super(a); // error CS0030: Cannot convert type 'int' to 'haxe.lang.Null<int>'
-    }
+	public function new(?a = 1) {
+		super(a); // error CS0030: Cannot convert type 'int' to 'haxe.lang.Null<int>'
+	}
 }
 
 #if (cs || java)
 
 private class C {
-    public function new(a) {}
+	public function new(a) {}
 }
 
 private class D extends C {
-    public function new(?a:Single = 1) {
-        super(a); // error CS0030: Cannot convert type 'int' to 'haxe.lang.Null<int>'
-    }
+	public function new(?a:Single = 1) {
+		super(a); // error CS0030: Cannot convert type 'int' to 'haxe.lang.Null<int>'
+	}
 }
 
 #end

+ 12 - 12
tests/unit/src/unit/issues/Issue3197.hx

@@ -2,18 +2,18 @@ package unit.issues;
 
 class Issue3197 extends Test {
 	function test() {
-        var v = "good";
-        for (i in 0...10) {
-            v = if (i == 1) "bad" else break;
-        }
-        eq(v, "good");
+		var v = "good";
+		for (i in 0...10) {
+			v = if (i == 1) "bad" else break;
+		}
+		eq(v, "good");
 
-        var a = [];
-        for (i in 0...10) {
-            var v = if (i == 1) i else continue;
-            a.push(v);
-        }
-        eq(a.length, 1);
-        eq(a[0], 1);
+		var a = [];
+		for (i in 0...10) {
+			var v = if (i == 1) i else continue;
+			a.push(v);
+		}
+		eq(a.length, 1);
+		eq(a[0], 1);
 	}
 }

+ 19 - 19
tests/unit/src/unit/issues/Issue3198.hx

@@ -10,24 +10,24 @@ private typedef C = {>A,}
 private typedef D = {>A, >B,}
 
 class Issue3198 extends Test {
-    function test() {
-        eq(getExtends((null : C)), "A");
-        eq(getExtends((null : D)), "A,B");
-    }
+	function test() {
+		eq(getExtends((null : C)), "A");
+		eq(getExtends((null : D)), "A,B");
+	}
 
-    static macro function getExtends(e) {
-        switch (Context.follow(Context.typeof(e))) {
-            case TAnonymous(_.get() => {status: AExtend(_.get() => tl)}):
-                var p = [];
-                for (t in tl) switch (t) {
-                    case TType(_.get() => dt, []):
-                        p.push(dt.name);
-                    default:
-                        throw false;
-                }
-                return macro $v{p.join(",")};
-            default:
-                throw false;
-        }
-    }
+	static macro function getExtends(e) {
+		switch (Context.follow(Context.typeof(e))) {
+			case TAnonymous(_.get() => {status: AExtend(_.get() => tl)}):
+				var p = [];
+				for (t in tl) switch (t) {
+					case TType(_.get() => dt, []):
+						p.push(dt.name);
+					default:
+						throw false;
+				}
+				return macro $v{p.join(",")};
+			default:
+				throw false;
+		}
+	}
 }

+ 1 - 1
tests/unit/src/unit/issues/Issue3214.hx

@@ -26,7 +26,7 @@ class Issue3214 extends unit.Test {
 	function test() {
 		var a = Int64.make(1,2);
 		var b = Int64.make(3,4);
-        var c = a * b;
+		var c = a * b;
 		eq(21, c.get().get());
 	}
 }

+ 3 - 3
tests/unit/src/unit/issues/Issue3217.hx

@@ -4,11 +4,11 @@ class Issue3217 extends Test
 {
 	public function test()
 	{
-      #if (cpp && !cppia)
+	  #if (cpp && !cppia)
 		var t:NativeClassStruct = null;
-      #else
+	  #else
 		var t:{ test:Int } = new NativeClass();
-      #end
+	  #end
 		t.test = 10;
 		eq(t.test,10);
 	}

+ 1 - 1
tests/unit/src/unit/issues/Issue3218.hx

@@ -9,6 +9,6 @@ class Issue3218 extends Test {
 		eq(2, a(1));
 
 		var f:haxe.Constraints.Function = function(){ return 12; }
-        eq(12, f());
+		eq(12, f());
 	}
 }

+ 2 - 2
tests/unit/src/unit/issues/Issue3244.hx

@@ -1,11 +1,11 @@
 package unit.issues;
 
 private abstract A(String) from String {
-    @:from static function fromInt(v:Int):A return "abc";
+	@:from static function fromInt(v:Int):A return "abc";
 }
 
 private class TestClass {
-    static public var a:A = 1;
+	static public var a:A = 1;
 	public var b:A = 1;
 
 	public function new() { }

+ 6 - 6
tests/unit/src/unit/issues/Issue3280.hx

@@ -2,16 +2,16 @@ package unit.issues;
 
 class Issue3280 extends Test {
 
-    static function recurse( i : Int, param : String ) {
-        if( i > 0 ) {
+	static function recurse( i : Int, param : String ) {
+		if( i > 0 ) {
 			param += iter(i, recurse.bind(_,param));
 		}
 		return param;
-    }
+	}
 
-    static function iter( v : Int, f) {
-        return f(v-1);
-    }
+	static function iter( v : Int, f) {
+		return f(v-1);
+	}
 
 	function test() {
 		eq("aaaa", recurse(3, "a"));

+ 18 - 18
tests/unit/src/unit/issues/Issue3292.hx

@@ -1,36 +1,36 @@
 package unit.issues;
 
 private class Component {
-    public static var TYPE : String = "type";
-    public function doSomething() { return TYPE; };
-    public function new() { };
+	public static var TYPE : String = "type";
+	public function doSomething() { return TYPE; };
+	public function new() { };
 }
 
 private class A {
-    var _components : Map<String, Component>;
+	var _components : Map<String, Component>;
 
-    public function new() {
-        _components = new Map<String, Component>();
-        _components.set( Component.TYPE, new Component() );
-    }
+	public function new() {
+		_components = new Map<String, Component>();
+		_components.set( Component.TYPE, new Component() );
+	}
 
-    @:generic public function get<T:(Component)>( classType : Class<T> ) : T {
-        return cast _components.get( Reflect.field( classType, "TYPE" ) );
-    }
+	@:generic public function get<T:(Component)>( classType : Class<T> ) : T {
+		return cast _components.get( Reflect.field( classType, "TYPE" ) );
+	}
 }
 
 private class B extends A {
-    public function new() {
-        super();
-    }
+	public function new() {
+		super();
+	}
 }
 
 class Issue3292 extends Test {
 	function test() {
-        var a : A = new A();
-        eq("type", a.get( Component ).doSomething());
+		var a : A = new A();
+		eq("type", a.get( Component ).doSomething());
 
-        var b : B = new B();
-        eq("type", b.get( Component ).doSomething());
+		var b : B = new B();
+		eq("type", b.get( Component ).doSomething());
 	}
 }

+ 2 - 2
tests/unit/src/unit/issues/Issue3333.hx

@@ -1,13 +1,13 @@
 package unit.issues;
 
 private abstract MyString(String) to String {
-    public function new (url:String) this = url;
+	public function new (url:String) this = url;
 	public inline function get() return this;
 }
 
 class Issue3333 extends Test {
 	function test() {
-        var f = MyString.new.bind("hey");
+		var f = MyString.new.bind("hey");
 		eq("hey", f().get());
 	}
 }

+ 5 - 5
tests/unit/src/unit/issues/Issue3338.hx

@@ -2,22 +2,22 @@ package unit.issues;
 
 class Issue3338 extends Test {
 	function test() {
-        var e:TestEnum = null;
-		
+		var e:TestEnum = null;
+
 		match(Val1, 0);
 		match(null, 1);
 		match(Val2, 2);
 	}
-	
+
 	function match(e:TestEnum, expected:Int) {
 		var matched:Int = -1;
-		
+
 		matched = switch (e) {
 			case Val1: 0;
 			case null: 1;
 			case _: 2;
 		}
-		
+
 		eq(matched, expected);
 	}
 }

部分文件因为文件数量过多而无法显示