CHANGES:
- Make the
unprocessed
alert fatal by default
(#1135) - support
-H
for hidden include dirs in OCaml 5.2
(#1137) - support
[@mel.*]
attributes in uncurried externals
(#1140) - add Worker types to
melange.dom
(#1147) - Add support for dynamic
import()
(#1164) - Fix code generation of custom
true
/false
constructors
(#1175) - Fix code generation of OCaml objects that refers to an init variable in scope
(#1183) - Support
[@mel.as "string"]
in variant definitions
(#884) - BREAKING: remove
[@@deriving jsConverter]
for variant definitions
(#884). Use[@mel.as "string here"]
instead. - Support OCaml 5.3 (#1168)
- Upgrade Stdlib to the OCaml 5.3 Stdlib
(#1182) - Support
[@mel.tag "the_tag"]
in variant definitions
(#1189)- combined with
[@mel.as ..]
in variant definitions and inline record
payloads, Melange can now express types for discriminated union object
shapes.
- combined with
- melange-ppx: don't silence warning 20 (
ignored-extra-argument
) for
%mel.raw
application
(#1166).- This change reverts the behavior introduced in
(#915). - The new recommendation is to annotate
%mel.raw
functions or disable
warning 20 at the project level.
- This change reverts the behavior introduced in
- ppx,core: propagate internal FFI information via attributes instead of adding
marshalled data in the native primitive name
(#1222) - melange-ppx: allow
@mel.unwrap
polyvariants not to have a payload
(#1239) melange.node
: fixBuffer.fromString
and add
Buffer.fromStringWithEncoding
(#1246)melange.node
: bind to all supported Node.jsBuffer
encodings in
Node.Buffer
(#1246)melange.js
: AddJs.FormData
with bindings to the
FormData API
(#1153,
#1270,
#1281melange.js
: AddJs.Blob
andJs.File
with bindings to the
Blob and
File APIs
(#1218)melange.js
: addTypedArray
types at the toplevel in theJs
module
(#1248)- BREAKING: remove
--mel-g
(#1234) - runtime(
melange.js
): port[@mel.send.pipe]
functions to[@mel.send]
,
taking advantage of the@mel.send
+ labeled argument improvement (see
above) (#1260,
#1264,
#1265,
#1266,
#1280,
#1278) - core: fix a crash related to finding constructor names in pattern matching triggered by dune's earlier implementation of
(implicit_transitive_deps false)
(#1238,
#1262) - core: pre-compute the closure param map for functions inlined with
--mel-cross-module-opt
(#1219) - BREAKING: ppx: print the
deprecated
alert for@@deriving abstract
at the
declaration site rather than at (all) usages
(#1269) - JS generation: prettify
for
loops
(#1275) - JS generation: improve formatting for
throw
andreturn
statements, JS
objects (#1286,
#1289) - JS generation: improve formatting for empty return and continue statements
(#1288) - JS generation: remove trailing spaces before commas in
export
(#1287) - JS generation: remove redundant switch cases branches
(#1295) - JS generation: move space before comma inside
for
definition
(#1296) - JS generation: add space before while loop condition
(#1297) - JS generation: improve indentation of parenthesized blocks
(#1293) - JS generation: add space after constructor comments
(#1294) - JS generation: improve identation of
switch
cases
(#1299) - JS generation: don't generate empty
default:
cases inswitch
(#1300) - JS generation: emit
module.exports
in CommonJS instead ofexports.x
(#1314) - JS generation: remove trailing newline after
switch
(#1313) - ffi: allow annotating
@mel.send
FFI with@mel.this
to specify which
parameter should represent the "self" argument.
(#1303,
#1310)- This improvement to the FFI allows expressing more FFI constructs via
labeled and optionally labeled arguments, e.g.external foo: value:string -> (t [@mel.this]) -> unit = "foo" [@@mel.send]
will now produce
t.foo(value)
instead ofvalue.foo(t)
. - It also allows removing usages of
[@mel.send.pipe: t]
in favor of
[@mel.send]
with[@mel.this]
, including when used with@mel.variadic
.
- This improvement to the FFI allows expressing more FFI constructs via
- ppx: deprecate
[@mel.send.pipe]
(#1321) - core: fix missed optimization on OCaml versions 5.2 and above, caused by
ocaml/ocaml#12236 generating
multiple function nodes forfun a -> fun b -> ...
in the Lambda IR.