Am 14. Oktober fand eine kleine Online-Konferenz HaxeIn 2020 statt . Einer der Redner war Alexander Kuzmenko , der Entwickler des Haxe-Compilers.
Alexanders Vortrag ist ein Bericht über die Arbeit seit Februar 2020 (als HaxeUp Hamburg von Inno Games moderiert wurde). Ich mache Sie auf eine Abschrift seiner Rede aufmerksam.

Was wurde in der Zwischenzeit getan?
benchs.haxe.org
, Haxe. , AlexHaxe.
https://benchs.haxe.org/, — github.
, . Haxe — , JVM - ( , ). , , .

Haxe 4.1
Haxe 4.1 ( Haxe 4.0). 4.1 :
- JVM ( JVM ). , .
- SSL Haxe (eval-)
- . , . .
- , , .
, Haxe 4.1 , , . ( ), Haxe 4.1 IDE.

dts2hx
2 Haxe 4.1 dts2hx — TypeScript Haxe-, JavaScript. , JavaScript-.
Haxe Foundation, dts2hx ( , ).

Haxe 4.1:
JVM-. — - ( pull request ), .. - — Java-. ( ), , , , , Haxe- JVM - Java. JVM- — Haxe, :
- Java, ,
- Haxe - JVM, JavaScript-
- . — jar-
- JVM — , Haxe. , , Java — ( ). , formatter ( formatter ) JVM- .

SSL eval- ( Haxe) https- .
API Mbed TLS SSL ( Haxe SSL).

haxe.Exception
.
(, , , ). Haxe 4.1 (.. ), haxe.Exception
( ) -.
, haxe.Exception
. , , haxe.Exception
(, ), "" , haxe.Exception
. , Dynamic
(.. ) Haxe 4.1.

: Haxe haxe.CallStack
, . (rethrow exception), . ( ).

, :
- . , - ( ), ,
-
haxe.Exception
. , Haxe - . , Haxe jar jar Java, , Haxe-, Java- - .

catch
— , haxe.Exception
.

Tail recursion elimination
(tail recursion elimination) .
, , , ( ).
, , .

( -D analyzer_optimize
).
, (inline), (final) . , ( ).
-D no_tre
.

Haxe 4.1 :
- ,
- Null- (Null Safety) — StrictThreaded, , . Strict- , .
- , ( JavaScript Source Maps) — .
-
Std.is
(deprecated),Std.isOfType
.is
( Haxe 4.2).

Haxe Evolution 2020
- Haxe Evolution, Haxe ( , , ).
. issue , .

— Void
" " (unit type). , : Void
, , , - . , Void
(Promise
), . Haxe .
, .. , , Void
, , Void
.


, Haxe , — . . , : , @.haxe.meta.MetadataType
, . , .. , — , . , .



- . : , ( ); , - , .


Haxe, . , this
( ). , . , : Haxe as
, , .

- (generic types) . , (, ) - (, String
). , typedef
, , , .
, , , , , , , ?

this
, , . , .. . , , .

(type parameter variance of enum).
, , enum
Int
, enum
Float
( ) — , . , , , . , .
, .. — enum
, (, ). , C#, in
out
-.

Haxe 4.2
, Haxe .
Haxe 4.2. , .. , ( , ).
:
(Module-level static fields), , - . , , . , .

, . "" Java:
- ,
Shape
, API — Shape
vertices()
, . Square
.
, - , .

sys.thread.Thread
Haxe 4.2 ( , ) — (event loops) ( NodeJS libuv):
- ,
- . , - (callback)
- , .. Haxe 4.2, , , . Haxe 4.2 , .

API sys.thread.Thread
— Thread.createWithEventLoop()
, , . , , , , :
, :
secondary.events.run(() -> { trace(‘This is printed from the secondary thread’); });
, secondary
.
, , , secondary
, , :
mainThread.events.run(() -> { trace(‘This is printed from the main thread’); });
( ).
, .. Haxe , secondary
, , , secondary
. Sys.sleep(2)
.

(, Thread.create()
, API ) , sys.thread.NoEventLoopException
.
: secondary
, , ( secondary
).

— "", , , .
: "" , , ( , ) . , , , , , Sys.sleep(2)
— .

( ):
- ( )
- (variance forwarding), "" (underlying type)
- (constructor forwarding). Haxe 4.1 (
@:forward
@:forwardStatics
), Haxe 4.2@:forward.new
.

:
, (transitive casting), @:transitive
. .
("" ). Haxe 4.1 (Array<Int>
) , Collection
. , Collection
Array<Int>
( Items
). Haxe 4.2 ( ) — @:transitive
Collection
, Items
, , Collection
Array<Int>
(.. Items
Array<Int>
):
var collection:Collection = [123];
, Array<Int>
Collection
:
var array:Array<Int> = collection;

(variance forwarding) . :
Haxe 4.1 Array<Int>
Array<Money>
, Money
— , Int
. , @:forward.variance
, "" , , Int
, Money
.
Any
, . Dynamic
, -. Any
.

, :
- Haxe 4.2
is
. Haxe 4.1 — .is
Std.isOfType()
( ), . - Python API —
sys.thread.Thread
. - (object inlining). . , , , .
- . , , 2- Haxe ( 1 2). , , , , .

WIP
Haxe 4.2, :
API. API , API.
API C API , , API .
API , .

API Libuv, Haxe (eval-), API Libuv , .
OCaml- Luv.
, Libuv ( ).

:
- Haxe
- Es wird plattformübergreifende Implementierungen von Ganzzahltypen wie 8- und 16-Bit-Ganzzahlen mit Vorzeichen und Vorzeichen usw. geben.
- Es werden auch Methoden mit einer variablen Anzahl von Argumenten (Restargumente) unterstützt. Die Arbeiten an ihnen hatten bereits begonnen, wurden jedoch verschoben.

Vielen Dank für Ihre Aufmerksamkeit! Ich hoffe, Sie fanden dieses Material interessant.