|
3 | 3 | > **Tags:** |
4 | 4 | > |
5 | 5 | > - :boom: [Breaking Change] |
6 | | -> - :eyeglasses: [Spec Compliance] |
7 | 6 | > - :rocket: [New Feature] |
8 | 7 | > - :bug: [Bug Fix] |
9 | 8 | > - :memo: [Documentation] |
|
14 | 13 |
|
15 | 14 | #### :boom: Breaking Change |
16 | 15 |
|
| 16 | +- `\"_"` is no longer allowed as a quoted identifier, as it couldn't be told apart from the `_` wildcard and placeholder. https://github.com/rescript-lang/rescript/pull/8795 |
| 17 | +- Record syntax no longer creates or matches dicts, e.g. `let d: dict<int> = {foo: 1}`; it's an error pointing to `dict{...}`. https://github.com/rescript-lang/rescript/pull/8751 |
17 | 18 | - Remove the call-site `@inlined` attribute, which was parsed but never affected code generation. It is now reported as a misplaced attribute (warning 53). https://github.com/rescript-lang/rescript/pull/8734 |
18 | 19 | - Remove `@deriving(abstract)` and `@deriving(jsConverter)`. Use record types (with optional fields, mutable fields and `@as` renaming) and polymorphic variants directly instead. https://github.com/rescript-lang/rescript/pull/8729 |
19 | 20 |
|
20 | | -#### :eyeglasses: Spec Compliance |
21 | | - |
22 | 21 | #### :rocket: New Feature |
23 | 22 |
|
| 23 | +- Support Windows 11 on ARM by installing the x64 binaries, which Windows runs through its x64 emulation. https://github.com/rescript-lang/rescript/pull/8776 |
| 24 | +- Allow `$` in identifiers, e.g. `let count$ = signal(0)`. https://github.com/rescript-lang/rescript/pull/8791 |
| 25 | +- Allow an untagged variant to have both a boolean literal case and a boolean payload case, e.g. `@unboxed type t = | @as(true) A | B(bool)`, like for strings and numbers. https://github.com/rescript-lang/rescript/pull/8777 |
| 26 | + |
24 | 27 | #### :bug: Bug fix |
25 | 28 |
|
26 | | -- Allow `rescript clean` to remove generated files when the source module graph is invalid. https://github.com/rescript-lang/rescript/pull/8640 |
| 29 | +- Fix parser recovery and editor completion when a record or dict value is missing before a comma, e.g. `{a: , b: 1}`. https://github.com/rescript-lang/rescript/pull/8779 |
| 30 | +- Derive module names from file names consistently, fixing files like `Button.test.res` that could not reference `Button`, and `.res`/`.resi` pairs with dotted or non-ASCII names. https://github.com/rescript-lang/rescript/pull/8797 |
| 31 | +- Fix the formatter printing escaped identifiers starting with `_`, like `\"_'"`, in a form that doesn't parse. https://github.com/rescript-lang/rescript/pull/8795 |
| 32 | +- Fix references to a `@val` global reading a binding with the same name, e.g. a toplevel `let` declared before them. https://github.com/rescript-lang/rescript/pull/8785 |
| 33 | +- Evaluate the unused arguments of an inlined function call in parameter order. https://github.com/rescript-lang/rescript/pull/8786 |
| 34 | +- Fix shadowed variables in generated JS colliding with identifiers or external names containing `$`. https://github.com/rescript-lang/rescript/pull/8778 |
| 35 | +- Fix editor completion of values from modules included with `include await M`. https://github.com/rescript-lang/rescript/pull/8770 |
| 36 | +- Fix editor completion inside dict literals and dict patterns, which suggested untyped values. https://github.com/rescript-lang/rescript/pull/8770 |
| 37 | +- Report the required Node.js version 22 when the platform package can't be found. https://github.com/rescript-lang/rescript/pull/8770 |
| 38 | +- Fix JSX preserve mode emitting JSX that means something other than the compiled call, and keep more elements as JSX. https://github.com/rescript-lang/rescript/pull/8754 |
| 39 | +- Fix exhaustiveness and unused-case checks for dict patterns that match the same key in several cases, print their counter-examples as dict patterns, and reject a key matched twice in one pattern. https://github.com/rescript-lang/rescript/pull/8751 |
| 40 | +- Emit `"__proto__"` keys in object literals as computed keys, so they create a property instead of setting the prototype. https://github.com/rescript-lang/rescript/pull/8747 |
| 41 | +- Fix the formatter dropping attributes on dict literals and flattening nested dict spreads. https://github.com/rescript-lang/rescript/pull/8746 |
| 42 | +- Fix attributes on patterns being duplicated before `as` and dropped on constants when formatting. https://github.com/rescript-lang/rescript/pull/8750 |
27 | 43 | - Fix compiler crashes when wrapping values in `Some` or passing optional arguments whose types come from a transitive dependency. https://github.com/rescript-lang/rescript/pull/8719 |
28 | 44 | - Fix unused-pattern warnings for variant spreads reported without a location. https://github.com/rescript-lang/rescript/pull/8744 |
29 | 45 | - Keep `@warning("-4")` on `if` expressions when formatting; the formatter dropped it. https://github.com/rescript-lang/rescript/pull/8741 |
|
43 | 59 |
|
44 | 60 | #### :nail_care: Polish |
45 | 61 |
|
| 62 | +- Speed up type checking of record expressions and patterns with many fields whose type is not known from context. https://github.com/rescript-lang/rescript/pull/8799 |
| 63 | +- Print list literals with one list cell per line, so their output no longer grows quadratically with their length. https://github.com/rescript-lang/rescript/pull/8794 |
| 64 | +- Compile dict spreads to object spread syntax instead of `Object.assign`. https://github.com/rescript-lang/rescript/pull/8747 |
| 65 | +- Make compilation slightly faster and stop rewatch from copying files twice for modules with an interface. https://github.com/rescript-lang/rescript/pull/8769 |
| 66 | +- Speed up inlining decisions for large functions. https://github.com/rescript-lang/rescript/pull/8771 |
| 67 | +- Speed up the rewriting of JS globals shadowed by local bindings in nested functions. https://github.com/rescript-lang/rescript/pull/8772 |
| 68 | +- Speed up dead code elimination of toplevel bindings in large modules. https://github.com/rescript-lang/rescript/pull/8773 |
| 69 | +- Make .cmt and .cmti files smaller by no longer embedding a copy of the .cmi. https://github.com/rescript-lang/rescript/pull/8774 |
| 70 | +- Use the OCaml standard library's hash tables in the compiler. https://github.com/rescript-lang/rescript/pull/8786 |
| 71 | +- Use the OCaml standard library's hash tables for the compiler's hash sets, and always order the imports of a module used both with and without `default` the same way. https://github.com/rescript-lang/rescript/pull/8787 |
| 72 | +- Use the OCaml standard library's sets in the compiler. https://github.com/rescript-lang/rescript/pull/8789 |
| 73 | +- Use the OCaml standard library's maps in the compiler. https://github.com/rescript-lang/rescript/pull/8790 |
46 | 74 | - Represent explicit expression braces as `Pexp_braces` in parsetree v1 and format `else` branches consistently with `if` branches. https://github.com/rescript-lang/rescript/pull/8678 |
47 | 75 | - Omit redundant braces around multi-statement switch case bodies when formatting. https://github.com/rescript-lang/rescript/pull/8677 |
48 | 76 | - Avoid running `rescript-schema-ppx` and `sury-ppx` on source files without an `@schema` annotation. https://github.com/rescript-lang/rescript/pull/8662 |
|
51 | 79 |
|
52 | 80 | #### :house: Internal |
53 | 81 |
|
| 82 | +- Remove OCaml leftovers: unused warning numbers, the `Record_float_unused` representation, the `ns.braces` attribute name and unused `Ast_helper` functions. https://github.com/rescript-lang/rescript/pull/8805 |
| 83 | +- Remove the S-expression parsetree printer (`res_parser -print sexp`). https://github.com/rescript-lang/rescript/pull/8803 |
| 84 | +- Use one set of OCaml warning flags for the whole repository, including the editor analysis and tools. https://github.com/rescript-lang/rescript/pull/8796 |
| 85 | +- Remove the unused `Packed` and `Partial_class_expr` constructors from the `.cmt` format and bump its magic number. https://github.com/rescript-lang/rescript/pull/8793 |
| 86 | +- Make `dict` an abstract type instead of a record with a hidden field. https://github.com/rescript-lang/rescript/pull/8752 |
| 87 | +- Remove dead code from the compiler and rewatch. https://github.com/rescript-lang/rescript/pull/8756 |
| 88 | +- Represent dict patterns with a dedicated `Tpat_dict` typed tree node. https://github.com/rescript-lang/rescript/pull/8751 |
| 89 | +- Represent dict patterns with a dedicated `Ppat_dict` node. https://github.com/rescript-lang/rescript/pull/8749 |
| 90 | +- Represent dict literals with dedicated `Pexp_dict` and `Texp_dict` nodes. https://github.com/rescript-lang/rescript/pull/8746 |
54 | 91 | - Forward-port integer range pattern regression coverage from v12 to v13. https://github.com/rescript-lang/rescript/pull/8718 |
55 | 92 | - Remove the unused `res.iflet` encoding of `if let`, which the parser always rejects with a syntax error suggesting a `switch`. The error is unchanged. https://github.com/rescript-lang/rescript/pull/8741 |
56 | 93 | - Represent variant spread patterns (`...t`) with a dedicated `Ppat_variant_spread` parsetree node instead of `Ppat_type` with a `res.patVariantSpread` attribute, which remains only in the PPX wire representation. https://github.com/rescript-lang/rescript/pull/8742 |
|
62 | 99 | - Remove the unused `pat_record_label` alias from the current parsetree. https://github.com/rescript-lang/rescript/pull/8684 |
63 | 100 | - Remove the unused `Ppat_open` and `Tpat_open` AST nodes, with current-AST and CMT format bumps. https://github.com/rescript-lang/rescript/pull/8682 |
64 | 101 | - Represent ternary expressions with a dedicated parsetree node. https://github.com/rescript-lang/rescript/pull/8674 |
| 102 | +- Remove the compiler's own growable vector (`Vec`) in favor of plain arrays. https://github.com/rescript-lang/rescript/pull/8784 |
65 | 103 |
|
66 | 104 | # 13.0.0-alpha.6 |
67 | 105 |
|
|
0 commit comments