Skip to content

Releases: HaxeFoundation/haxe

5.0.0-preview.1

04 Jul 11:20

Choose a tag to compare

5.0.0-preview.1 Pre-release
Pre-release

2025-07-04 5.0.0-preview.1

Removal:

  • all : remove 32 bit windows builds (#11541)
  • all : move sys.db, php.Web and neko.Web to hx4compat lib (#11385)
  • all : move haxe.remoting to hx4compat lib (#11387)
  • all : remove haxe.Ucs2 (#12103)
  • hl : move some hl.Format into lib format/heaps (#11869)
  • js : remove previously deprecated untyped __js__ and friends (#11471)
  • java/cs : remove C# and Java targets (#11551)
  • macro : remove some API from haxe.macro.Compiler (#11540)
  • macro : remove CompilationServer.setModuleCheckPolicy options (#11615)

Breaking changes:

  • all : rework module resolution (#11168)
  • all : don't infer string on concat (#11318)
  • all : delay typer creation to after init macros (#11323)
  • all : disallow partial resolution (pack.SubType access when module is imported) (#11338)
  • all : don't create a class field for every enum field (#11452)
  • all : only set cf_expr_unoptimized if we think we need it (#11462)
  • all : fix the way optional arguments are handled when using bind (#11533)
  • all : don't bind foreign type parameters in definition mode (#11658)
  • all : disallow duplicate argument name (#11978)
  • all : fix types in null coal null check (#11726)
  • macro : Build macro order vs inheritance (#11582)
  • macro : disallow defining types into existing modules (#11845)

General improvements:

  • all : hxb (new server cache + pre compilation) (#11504)
  • all : rework module resolution (#11168)
  • all : add "Custom" target (#11128)
  • all : private getters/setters (#12204)
  • all : allow boolean operators in patterns (#11157)
  • all : explicitly apply default type parameter (#12002)
  • all : allow modification of loop var in IntIterator loop (#8581)
  • all : support overloading true extern constructors (#11979)
  • all : support f?.bind() (#11571)
  • all : rework defines (#12130, #12251)
  • all : abort compilation on first error with -D fail-fast (#11609)
  • all : add position and error message to decode_error.txt (#12128)
  • all : add configuration options for -D dump, set -D dump-ignore-var-ids by default (#12150, #12130)
  • all : add support for binary literal (#11627)
  • all : add support for --undefine to remove define (#11400)
  • all : add optional WUnsafeEnumEquality (#11813)
  • all : build macOS universal binaries (#11572)
  • all : [experiments] run parts of the compiler in parallel with -D enable-parallelism (#12070, #12134, #12081, #12252)
  • all : [std] add enum as haxe.Unit (#11563)
  • all : [std] add BigInteger type (#10750)
  • all : [std] add haxe.runtime.Copy (#11863)
  • all : [std] haxe.Timer.milliseconds (#12260)
  • all : [std] String.indexOf (#7402, #11569)
  • all : [std] add StringBuf.clear() (#11848)
  • all : [std] allow setting haxe.Exception.stack (#12213)
  • all : [std] Serializer: implement reset method (#12068)
  • all : [std] use Vectors in haxe.zip (#11034)
  • all : [messageReparting] pretty errors as default message reporting (#11587)
  • all : [messageReporting] add config to use absolute positions (#11439)
  • all : [display] diagnostics as json rpc (#11412)
  • all : [display] report null safety errors in diagnostics (#11729)
  • all : [display] add server/resetCache (#11482)
  • all : [server] add support for ipv6 addresses for --wait/--connect (#11310)
  • all : [server] improve GC stats tracking (#12246)
  • all : [server] remove custom ocaml GC handling (#12287)
  • hl : bump default hl_version to 1.15 for haxe 5 (#12065)
  • hl : add std.hl.Gc.getLiveObjects (#11599)
  • hl : add element type to HArray (#11734)
  • hl : optimize single char String and adding with empty string
  • hl : added guid type
  • hl : hl.Profile.event give code some meaning with enum abstract (#12262)
  • jvm : improve NativeOutput performance (#11944)
  • jvm : functional interface support (#11019)
  • cpp : add Tracy profiler extern (#11772)
  • cppia : generate full debug source paths (#12053)
  • js : use native maps when ES6 is enabled (#11698)
  • js : remove String.fromCodePoint polyfill for es6 (#11713)
  • js : add the canParse() and parse() static methods to URL (#11802)
  • js : add externs for the Screen Wake Lock API (#11421)
  • js : add externs for the Web Share API (#11423)
  • js : update Object and Symbol externs (#11331)
  • js : clean up ES5 implementation of StringMap.keys() (#11895)
  • js : add new WebGLPolygonMode extension (#12026)
  • js : add js.lib.NativeStringTools (#12127)
  • php : add externs for some POSIX functions (#11769)
  • macro : delay typer creation to after init macros (#11323)
  • macro : added Context.resolveComplexType
  • macro : add TypeTools.toBaseType() (#11153)
  • macro : add TypeTools.resolveTypeParameters (#11053)
  • macro : add PositionTools.toZeroRange(pos) to avoid messing up display requests (#11892)
  • macro : apply @:using after build macros (#11625)
  • macro : include module path in virtual file names (#11852)
  • macro : respect imports on @:build (#11373)
  • macro : [server] expose compilation server stats (#12290)
  • macro : [server] add memory print that support details for macro interpreter (#11644)
  • eval : atomics (#12275)

Bugfixes:

  • all : fix @:wrappedException type (#11140)
  • all : don't allow null-only switches if we need a value (#11366)
  • all : detect recursive hxmls (#11580)
  • all : use local name instead of temp name for ?? (#11464)
  • ...
Read more

4.3.7

09 May 14:39

Choose a tag to compare

2025-05-09 4.3.7

General improvements:

  • all : update bundled haxelib version to 4.1.1
  • all : update bundled neko version to 2.4.1 (#12183)
  • all : use -w rules instead of defines to configure warnings (#11826, #12013)

Bugfixes:

  • all : fix compiler hanging issue (#11820)
  • all : local statics fixes (#11803, #11849)
  • all : fix for inline constructor bug triggering "Unbound variable" (#12169)
  • all : check caught error position when recovering from match typing failure (#12098)
  • macro : local statics vs ExprTools.map (#12030)
  • eval : https fixes (mbedtls update) (#11646)
  • eval : ssl cert verification failures on windows (#11838)
  • hl/c : fix comparison of HArray,HArray and HBytes,HBytes (#11610)
  • cppia : generate scriptable functions for overriden functions (#11773)

4.3.6

07 Aug 12:23

Choose a tag to compare

2024-08-07 4.3.6

Bugfixes:

  • display : do not define "display" for json rpc diagnostics (#11746)
  • cpp : null check interfaces (#11743)
  • hl : ignore WANT_READ/WANT_WRITE errors when the socket is known to be blocking (#11655)
  • hl : fix weird compiler error (#11690)
  • jvm : fix --java out -D jvm deprecation warning (#11739)
  • macro : Context.reportError should not abort build macros (#11741)

4.3.5

18 Jul 14:30

Choose a tag to compare

2024-07-18 4.3.5

General improvements:

  • all : macOS universal binaries (#11572)
  • display : migrated diagnostics to Json RPC (#11707)
  • macro : expose TVar VStatic flag in macros. (#11683)

Bugfixes:

  • all : fix @:structInit with getter + setter (#11662)
  • all : add missing recursion when checking abstract casts (#11676)
  • all : fail nicer if unify_min can't find a common type (#11684)
  • all : fix pretty errors failure (#11700)
  • all : disallow local statics when inlining (#11725)
  • display : unused pattern variables should be marked as unused (#7282)
  • display : diagnostics miss "used without being initialized" errors (#7931)
  • display : recursive inline is not supported on enum abstract constructor (#11177)
  • display : Void as value error disappears on second compilation (#11184)
  • display : false positives of "This cast has no effect, but some of its sub-expressions" (#11203)
  • cpp : inherit @:unreflective on generic classes
  • hl : fix bit shift + assignment in while loop header (#10783)
  • hl : fix do-while loop in genhl+hlopt (#11461)
  • hl/c : use uint64 instead of uint64_t for shift cast (#11721)
  • macro : don't choke on namePos for reification pattern matching (#11671)

Deprecation / future version handling:

  • macro : Compiler.include() warning when used outside init macros

4.3.4

04 Mar 19:44

Choose a tag to compare

2024-03-04 4.3.4

General improvements:

  • all : allow @:using with Class and Enum (#11553)
  • display : expose list of metadata/defines (#11399)

Bugfixes:

  • all : typedef vs. GADT (#11446)
  • all : don't double-throw exceptions (#11175)
  • all : fix some abstract inlining failures (#11526)
  • all : fix JsonPrinter empty parent class (#11560)
  • all : dce: clean up operator handling (#11427)
  • all : analyzer: deal with unreachable block in binops (#11402)
  • all : analyzer: don't recursively check enum values when const propagating (#11429)
  • all : analyzer: fix check for inlined purity meta
  • display : fix errors from parser missing in diagnostics (#8687)
  • display : fix display services with static extension (#11285)
  • display : fix display services with safe navigation (#11205)
  • hl : hlopt rework try-catch control flow (#11581)
  • hl/c : fix reserved keywords (#11408)

Deprecation / future version handling:

  • all : don't infer string on concat, when using -D haxe-next (#11318)
  • all : handle optional arguments with bind, when using -D haxe-next (#11533)
  • macro : build order vs inheritance, when using -D haxe-next (#11582)
  • macro : deprecate some API from haxe.macro.Compiler (see #11540)
  • java/jvm : warn about --java ... -D jvm vs --jvm ...

4.3.3

17 Nov 19:20

Choose a tag to compare

2023-09-17 4.3.3

General improvements:

  • all : improve extra field error range (#11335)
  • all : better error messages for --connect
  • hl : improve error message when hl_version is missing (#11086)
  • hl/c : compiler now adds hlc define when targeting hl/c (#11382)
  • macro : update macro API restriction warnings when using -D haxe-next (#11377)

Bugfixes:

  • all : handle non existing files for positions in pretty errors (#11364)
  • all : metadata support for local static vars
  • all : catch trailing invalid syntax in string interpolation (#10287)
  • eval : fix Array.resize retaining values (#11317)
  • eval/hl : fix catching haxe.ValueException (#11321)
  • hl : make genhl respect Meta.NoExpr (#11257)
  • hl : don't add bindings for non existing methods
  • hl/c : add missing I64 mod support
  • hl/c : rework reserved keywords (#11293, #11378)
  • hl/c : fix Int64 unsigned right shift overflow (#11382)
  • java/cs: fix stack overflow from closures constraints (#11350)
  • js : DOMElement insertAdjacentElement should not be pure (#11333)
  • macro : catch trailing invalid syntax in Context.parseInlineString (#11368)
  • macro : fix TDAbstract without flags in haxe.macro.Printer

4.3.2

01 Sep 15:02

Choose a tag to compare

2023-09-01 4.3.2

General improvements:

  • all : do not raise error on no-op reification outside macro

Bugfixes:

  • all : don't infer Null if it already is Null (#11286)
  • all : fix ?? inference and precedence (#11252)
  • all : bring back forced inline (#11217)
  • all : allow non constant "inline" var init with -D no-inline (#11192)
  • all : improve @:enum abstract deprecation warning handling (#11302)
  • all : fix some stack overflow with pretty errors
  • display : fix go to definition with final (#11173)
  • display : fix completion requests with @:forwardStatics (#11294)
  • eval : fix MainLoop.add not repeating (#11202)
  • hl/eval/neko : fix exception stack when wrapping native exceptions (#11249)
  • macro : map this when restoring typed expressions (#11212)
  • macro : safe navigation fix for ExprTools.map (#11204)
  • macro : safe navigation fix for haxe.macro.Printer (#11206)
  • macro : macro generated EVars position fixes (#11163)
  • macro : fix abstract casts for local statics (#11301)
  • macro : add flags to TDAbstract to be able to construct enum abstracts (#11230)
  • nullsafety : make break/continue expressions not-nullable (#11269)
  • nullsafety : handle return in assignment (#11114)

4.3.1

28 Apr 19:59

Choose a tag to compare

2023-04-28 4.3.1

Breaking changes:

  • all : namespace message reporting defines (#11142)

General improvements:

  • all : support deprecation for defines

Bugfixes:

  • all : fix --times with compilation server (#11091)
  • all : fix default type parameters not respecting imports (#11161)
  • all : fix bytecode bindings issues (#11098)
  • macro : allow local statics in macro functions (#11096)
  • cpp : fix AtomicInt warnings on cppia (#11105)
  • cpp : fix deprecated implicit casts of cpp.Int64 (#10998)
  • cpp : add white space around template type syntax (#11107)
  • java : don't check native signatures on extern functions (#11131)
  • lua : remove non existent luautf8 charCodeAt extern (#11097)

4.3.0

06 Apr 05:53

Choose a tag to compare

2023-04-06 4.3.0:

New features:

  • all : support defaults for type parameters (#10518)
  • all : support @:op(a()) on abstracts (#10119)
  • all : support abstract keyword to reference the abstract (#10513)
  • all : support static var at expression-level (#10555)
  • all : support ?. safe navigation operator (#10561)
  • all : added ?? null coalescing operator (#10428)
  • all : add -w compiler option to configure warnings (#10612)
  • all : added new error reporting modes (#10863)
  • all : support custom metadata and defines (#10858)

General improvements:

  • all : made various optimizations in the analyzer
  • all : made various improvements to diagnostics
  • all : made various improvements to null-safety
  • all : optimize .bind for instance methods (#10737)
  • all : improved various parser error messages
  • all : improved compilation server performance
  • all : improved code generation for try/catch (#10519)
  • all : infer property accessor type from the property (#10569)
  • all : improved inference of local functions typed against abstracts (#10336)
  • all : improved completion on module-level fields
  • all : improved handling of native libraries on the compilation server
  • all : improved performance when generating locals (#10648)
  • all : made Std.parseInt more consistent across targets (#10664)
  • all : infer null literals as Null<?> (#7736)
  • all : made field access errors more consistent (#10896)
  • all : consistently allow trailing commas (#11009)
  • all : migrated all relevant targets to PCRE2 (#10491)
  • all : made analyzer reconstruct do-while loops (#7979)
  • all : improved restrictions on init macros (#11043)
  • all : improved positions of @:structInit fields (#9318)
  • macro : support map literals in Context.makeExpr (#10259)
  • macro : added haxe.macro.Compiler.getConfiguration() (#10871)
  • macro : added withImports and withOption to haxe.macro.Context
  • macro : added getMacroStack and onAfterInitMacros to haxe.macro.Context (#11043)
  • macro : added haxe.macro.Context.makeMonomorph (#10728)
  • eval : added dictionary mode to objects, increasing performance in some cases (#10284)
  • eval : fixed Sys.exit handling messing up the compilation server (#10642)
  • eval : added -D eval-print-depth and -D eval-pretty-print (#10952, #10963)
  • cpp : supported type parameters on extern classes (#10415)
  • cpp : haxe.Int64 improvements (#9935)
  • cpp : non-blocking process exit code reading (#10321)
  • js : improved type names for debugger (#10894)
  • lua : added SSL implementation (#10593)
  • lua : fixed String API when -D no-inline was in place (#11057)
  • lua : non-zero exit code in case of uncaught exception (#11082)
  • java : deal with default implementations when loading extern libraries (#10466)
  • jvm : improved closure naming (#10571)
  • jvm : supported --jvm dir (#10614)
  • jvm : added some missing TShort and TFloat handling (#10722)
  • jvm : added experimental support for functional interfaces (#11019)
  • php : added and fixed several extern functions

Standard Library:

  • all : added atomic operations to several targets (#10610)
  • all : added Vector.fill (#10687)
  • sys : added sys.thread.Condition and Semaphore (#10503)
  • sys : added Http.getResponseHeaderValues to deal with multiple values of same key (#10812)
  • sys : make Sys.environment consistent between targets (#10460)
  • sys : consistent way to unset environment variables with Sys.putEnv (#10402)

Bugfixes:

  • all : properly disallowed macro reification in invalid places (#10883)
  • all : fixed behavior when extending abstract classes with final fields (#10139)
  • all : addressed some issues with constructor inlining (#10304)
  • all : fixed pattern matcher bug related to null-guards (#10291)
  • all : fixed weird parser behavior on first offset in files (#10322)
  • all : fixed various issues related to the final modifier
  • all : fixed various issues related to overload handling
  • all : fixed precedence of => vs. ?: (#10455)
  • all : made error positions in structure declarations more accurate (#9584)
  • all : brought back proper check when accessing super fields (#10521)
  • all : fixed @:publicFields on abstracts (#10541)
  • all : inherited some metadata to @:generic implementation classes (#10557)
  • all : fixed various problems in EventLoop and MainLoop
  • all : fixed infinite recursion from invalid inheritance (#10245)
  • all : fixed strange interaction between static extensions and macro functions (#10587)
  • all : fixed problems with @:generic on the compilation server (#10635)
  • all : fixed Context.onTypeNotFound being called multiple times for the same thing (#10678)
  • all : fixed type parameter problem involving abstract classes and interfaces (#10748)
  • all : fixed #if (a != b) yielding true for nonexistent values (#10868)
  • all : fixed interaction between @:generic and abstract class (#10735)
  • all : fixed @:using loading types too eagerly (#10107)
  • all : fixed parser ignoring subsequent documentation comments (#10171)
  • all : fixed parser function messing up unrelated file state in some cases (#10763)
  • all : unified Map printing to always use [] (#9260)
  • cpp : fixed problem with cpp.Pointer being used in enum arguments (#10831)
  • macro : improved handling of macro this expressions (#10793)
  • eval : fixed bit shift operations > 31 (#10752)
  • eval : fixed Bytes.toString causing an internal exception (#10623)
  • jvm : fixed @:native processing (#10280)
  • jvm : fixed Type.getEnumConstructs on native enums (#10508)
  • jvm : fixed @:volatile being ignored (#10594)
  • jvm : fixed some hashing issue when pattern matching on emojis (#10720)
  • jvm : fixed stack handling on return return (#10743)
  • hl : fixed various code generation problems
  • python : fixed SslSocket for newer python versions (#8401)
  • python : fixed syntax issue related to Vector (#11060)

4.2.5

06 Mar 08:56

Choose a tag to compare

2022-03-06 4.2.5:

New features:

  • php : support PHP attributes generation #9964

Bugfixes:

  • all : fixed compiler crash in complex constraints chains #10445
  • all : fixed timers execution order for timers with small time delta #10567
  • js : fixed constructors with rest arguments when compiling for ES3, ES5 #10490
  • php : excluded E_DEPRECATED notices from error reporting #10502
  • php : fixed safe casts to native arrays #10576
  • nullsafety : fixed false error on extern var fields without initialization #10448