2018-02-23: 4.0.0-preview.3
See full commit history at 4.0.0-preview.2...4.0.0-preview.3, notable changes below:
New features:
- all : added new function type syntax (
(a:Int, b:String)->Void
) (#6645) - all : added column to StackItem.FilePos (#6665)
- all : added
-D warn-var-shadowing
- all : added haxe.Log.formatOutput (#6738)
- js : added js.Syntax class for generating unsupported JavaScript syntax in a type-safe analyzer-friendly way
- js : added js.Map and js.Set and js.JsIterator extern definitions (ES6)
- hl : added hl.Format.digest, use it for native Sha1/Md5
General improvements and optimizations:
- all : made all non-warning/non-error compiler messages output to stdout (#4480)
- all : make DCE keep constructor if any instance field is kept (#6690)
- all : make
final
in structures use class notation - display : added
this
andsuper
to toplevel completion (#6051) - php : implemented direct method comparison. No need to use
Reflect.compareMethods()
- php : added
php.Syntax.code()
instead of deprecateduntyped __php__()
(#6708) - php : added methods to
php.Syntax
for each php operator:??
,?:
,**
etc. (#6708) - python : add ssl support for http requests
- python : improve Sys.print(ln) code generation (#6184)
- js : generate faster code for
x.iterator()
calls (#6669) - js : rework exception handling, added js.Lib.getOriginalException (#6713)
- js : generate
value instanceof MyClass
instead ofStd.is(value, MyClass)
(#6687) - js : use lazy getter for HaxeError.message instead of calling String(val) in the ctor (#6754)
Removals:
- php : removed
php.Syntax.binop()
(#6708)
Deprecations:
- php : deprecated support for
untyped __php__
,untyped __call__
etc. Usephp.Syntax
instead.
Bugfixes:
- all : delay interface accessor generation properly (#6225, #6672)
- all : fixed unbound variable error in anonymous functions (#6674)
- all : fixed abstract
@:to
used whenfrom
is available in a specific case (#6751) - all : sys.Http: fix chunked encoding handling (#6763)
- all : fix some invalid Json being accepted by haxe.format.JsonParser (#6734)
- all : fixed haxe.format.JsonPrinter for instances of classes to make it produce consistent result across targets (#6801)
- all : fixed autogenerated constructor for extending @:structInit classes (#6822, #6078)
- js : fixed saving setter to
tmp
var before invocation (#6672) - lua : fix toString behavior in the case of -0 (#6652)
- lua : properly bind field functions when passed as arguments (#6722)
- php : don't fail on generating import aliases for classes with the similar names (#6680)
- php : fixed
Sys.environment()
to also return variables set bySys.putEnv()
- php : fixed
sys.net.Socket.bind()
(#6693) - php : fixed appending "sqlite:" prefix to the names of files created by
sys.db.Sqlite.open()
(#6692) - php : made php.Lib.objectOfAssociativeArray() recursive (#6698)
- php : fixed php error on parsing expressions like
a == b == c
(#6720) - php : fixed multiple file uploads in php.Web.parseMultiPart() (#4173)
- php : fixed an issue with "Object" used as a class name for PHP 7.2 (it's a new keyword in php) (#6838)
- eval : don't lose dynamic function inits from parent classes (#6660)
- cs : fix order-dependent enum type parameter issue (#6016)