Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Benchmarks Rust |
7f07380 to
ca0c834
Compare
WalkthroughThis change introduces a new optional field, Changes
Sequence Diagram(s)sequenceDiagram
participant Options
participant AstScanner
participant ScanResult
participant EcmaViewFactory
participant EcmaView
Options->>AstScanner: new(options)
AstScanner->>ScanResult: scan()
Note right of ScanResult: If HMR enabled,<br>initialize hmr_hot_ref
EcmaViewFactory->>ScanResult: scan(ast)
ScanResult->>EcmaViewFactory: { hmr_hot_ref, ... }
EcmaViewFactory->>EcmaView: create({ hmr_hot_ref, ... })
sequenceDiagram
participant HmrFinalizer
participant AST
participant Expr
HmrFinalizer->>AST: visit_expression(expr)
AST->>Expr: check import.meta.hot
alt is import.meta.hot
HmrFinalizer->>Expr: rewrite to hot_<module_name> variable
end
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI ⛔ Files ignored due to path filters (3)
📒 Files selected for processing (8)
🧰 Additional context used🧬 Code Graph Analysis (1)crates/rolldown/src/hmr/hmr_ast_finalizer.rs (2)
⏰ Context from checks skipped due to timeout of 90000ms (12)
🔇 Additional comments (15)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
✅ Deploy Preview for rolldown-rs canceled.
|
…sts (#4391) <!-- Thank you for contributing! --> ### Description - Closes: #4390 - Related: #4370 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Bug Fixes** - Improved handling of hot module replacement to prevent potential runtime errors when hot module references are missing. - **Tests** - Added new test files and configuration to verify correct behavior when accessing hot module replacement features. <!-- end of auto-generated comment: release notes by coderabbit.ai -->

Description
The
import.meta.hot.invalidateis execute at hmr, The originalimport.meta.hotis dependent on the module execute order, it will break atimport.meta.hot.invalidate.So the pr intend to fix it.
${reprname}_hot.