diff --git a/CHANGELOG.md b/CHANGELOG.md index a81f259ce0..e9732e00ff 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -32,6 +32,7 @@ #### :house: Internal +- Make expression attributes immutable in the current parsetree, now that editor refactors construct new expression nodes. https://github.com/rescript-lang/rescript/pull/8685 - Remove the unused `pat_record_label` alias from the current parsetree. https://github.com/rescript-lang/rescript/pull/8684 - 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 - Represent ternary expressions with a dedicated parsetree node. https://github.com/rescript-lang/rescript/pull/8674 diff --git a/compiler/ml/parsetree.ml b/compiler/ml/parsetree.ml index c1fed9be38..f8e771eee8 100644 --- a/compiler/ml/parsetree.ml +++ b/compiler/ml/parsetree.ml @@ -262,8 +262,7 @@ and pattern_desc = and expression = { pexp_desc: expression_desc; pexp_loc: Location.t; - (* Hack: made pexp_attributes mutable for use in analysis exe. Please do not use elsewhere! *) - mutable pexp_attributes: attributes; (* ... [@id1] [@id2] *) + pexp_attributes: attributes; (* ... [@id1] [@id2] *) } and expression_desc =