Closed cannorin closed 2 years ago
↑ js_of_ocaml-compiler
seems to be failing to compile on older versions of OCaml in *nix?
Build failure is related to https://github.com/ocsigen/js_of_ocaml/pull/1186 and can be ignored, at least for now.
Could you please check this PR? @mlasson
Ok, will do as soon as possible. Do you need a new release as well ?
Yes, new release please too 🙂
I tweaked your "duplicate checks" to forbid:
type t =
| A [@js 3]
| B [@js 3.0]
[@@js.enum]
and
type t =
| A [@js 3]
| B [@js 3.0000000000000000001]
[@@js.enum]
but also :
type t =
| A [@js 3.0]
| B [@js 3.0000000000000000001]
[@@js.enum]
Thanks @mlasson @cannorin ❤️
Related: https://github.com/ocsigen/ts2ocaml/issues/39 Closes #108.
This PR allows float values to be used inside
[@js]
attribute, which also allows binding to float enums and discriminated union using float value as a discriminator.This PR also optimizes the generated
match
statements when they only have a default case with no binding.