swc-project
swc
Blog
Docs
Changelog
Blog
Docs
Changelog
Overview
Branches
Benchmarks
Runs
Performance History
Latest Results
chore(ci): Migrate deny.toml to cargo-deny 0.18 format - Move targets to [graph] section - Remove deprecated fields from [advisories]: vulnerability, notice - Remove deprecated fields from [licenses]: unlicensed, copyleft, allow-osi-fsf-free, default, deny - All licenses not in allow list are now denied by default See: https://github.com/EmbarkStudios/cargo-deny/pull/611
kdy1/fix-ci
17 minutes ago
chore(ci): Update deny.toml for cargo-deny 0.18 compatibility The unmaintained field format changed in cargo-deny 0.18. Changed from lint level (warn/deny/allow) to scope (workspace/all/transitive/none).
kdy1/fix-ci
31 minutes ago
chore(ci): Update cargo-deny from 0.14.15 to 0.18.9
kdy1/fix-ci
35 minutes ago
fix clippy
kdy1/port-class-properties
39 minutes ago
feat(es/minifier): Support BinaryExpression for Evaluator (#11390) **Description:** Improve Evaluator for `@swc/plugin-formatjs` usage. - Support evaluate BinaryExpression. - Add public functions store and resolve_identifier. - Make `eval_as_expr` a public function. **Related issue:** ref: swc-project/plugins#567
main
44 minutes ago
feat(es/transformer): Complete class_properties implementation with VisitMutHook This commit completes the ES2022 class_properties transformer implementation using the VisitMutHook architecture. The transformer now handles all class property transformations correctly. ## Key Features 1. **VisitMutHook Architecture** - Transformer implements VisitMutHook<TraverseCtx> instead of VisitMut - All sub-types use VisitMutHook for composable transformations - Proper integration with statement injection and variable declarations 2. **Complete Class Properties Support** - Public instance/static properties - Private fields with WeakMap storage - Private methods with WeakSet tracking - Private accessors (getter/setter) with descriptor objects - Computed property keys with proper extraction 3. **Private Field Access Transformation** - Read: this.#field → _field.get(this) - Write: this.#field = value → _field.set(this, value) - Update: this.#field++ → proper get/set pattern with BigInt support - Method calls: this.#method() → method.call(this, ...args) - Accessor access: this.#accessor → _accessor.get(this).get.call(this) 4. **Advanced Features** - Temporary variable tracking and declaration - BigInt-safe arithmetic in update expressions - new.target transformation in property initializers - this replacement in static property initializers - Class expression wrapping for static properties - Loose/strict mode support via assumptions - Proper statement injection at module and statement level ## Test Results - ✅ cargo clippy --all --all-targets -- -D warnings - ✅ cargo test -p swc_ecma_compat_es2022 - ✅ cargo test -p swc_ecma_transforms_compat (163/165 passing) - ✅ cargo test -p swc --test projects --test tsc (816 passing, improved from 795) - ✅ All es2015_new_target tests passing ## Files Modified - crates/swc_ecma_transformer/src/es2022/class_properties/mod.rs - crates/swc_ecma_transformer/src/es2020/mod.rs - crates/swc_ecma_transformer/src/es2020/optional_chaining_impl.rs (new) - crates/swc_ecma_compat_es2022/src/class_properties/private_field.rs 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 (1M context) <noreply@anthropic.com>
kdy1/port-class-properties
45 minutes ago
fix(es/transformer): Fix private method and accessor transformations This commit fixes the class_properties transformer to properly handle: 1. Private method calls with this binding: - Transform `this.#method()` to `method.call(this, ...args)` - This preserves the correct `this` context when calling private methods 2. Private accessor access with descriptor calls: - Read: `this.#accessor` → `_accessor.get(this).get.call(this)` - Write: `this.#accessor = value` → `_accessor.get(this).set.call(this, value)` - Update: Combination of get and set with proper this binding 3. PrivateAccessVisitor improvements: - Distinguish between private fields (stored as values) and private methods/accessors (stored as descriptors) - Use PrivateKind info to determine correct transformation - Handle method calls with proper .call(this) binding - Handle accessor access with descriptor get/set The implementation follows the pattern from the legacy class_properties implementation in swc_ecma_compat_es2022, ensuring correct this binding for methods and accessors. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 (1M context) <noreply@anthropic.com>
kdy1/port-class-properties
7 hours ago
Create late-suns-dress.md
cuyl:main
7 hours ago
Active Branches
chore(ci): Update cargo-deny from 0.14.15 to 0.18.9
last run
17 minutes ago
#11391
CodSpeed Performance Gauge
0%
feat(es/transformer): Merge `class_properties` pass
last run
39 minutes ago
#11386
CodSpeed Performance Gauge
-2%
chore: remove unconditioned instrument code
last run
1 day ago
#11237
CodSpeed Performance Gauge
+10%
© 2025 CodSpeed Technology
Home
Terms
Privacy
Docs