Skip to content

Commit 6ad0735

Browse files
authoredNov 14, 2024··
refactor(es/compat): Use special span instead of passing static_blocks_mark (#9725)
**Description:** Let's make an assumption in the code: the use of dummy span as a private class field name is generated by us, it is there simply because it is necessary to maintain the order of side effect execution, its name is not referenced elsewhere, so we can safely remove its name. This is a breaking change for Rust users.
1 parent 9f8c14f commit 6ad0735

File tree

50 files changed

+638
-905
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+638
-905
lines changed
 

‎.changeset/smart-cherries-sleep.md

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
swc_common: patch
3+
swc_ecma_compat_es2022: major
4+
---
5+
6+
refactor(es/compat): Use dummy span instead of passing `static_blocks_mark`

‎crates/swc/src/builder.rs

-1
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,6 @@ impl<'a, 'b, P: Pass> PassBuilder<'a, 'b, P> {
215215
constant_super: assumptions.constant_super,
216216
set_public_fields: assumptions.set_public_class_fields,
217217
no_document_all: assumptions.no_document_all,
218-
static_blocks_mark: Mark::new(),
219218
pure_getter: assumptions.pure_getters,
220219
},
221220
},

0 commit comments

Comments
 (0)
Please sign in to comment.