mirror of
https://github.com/swc-project/swc.git
synced 2024-10-04 12:18:08 +03:00
fix(es/minifier): Abort seq inline on recursive usage (#8887)
**Related issue:** - Closes #8841
This commit is contained in:
parent
839bbfd78c
commit
cd4548fd8c
@ -2308,7 +2308,7 @@ impl Optimizer<'_> {
|
||||
can_take_init = true;
|
||||
}
|
||||
|
||||
if usage.inline_prevented {
|
||||
if usage.inline_prevented || usage.used_recursively {
|
||||
return Ok(false);
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,4 @@
|
||||
export const k = (() => {
|
||||
var x = x;
|
||||
return x;
|
||||
})();
|
@ -0,0 +1,2 @@
|
||||
var x;
|
||||
export const k = x;
|
Loading…
Reference in New Issue
Block a user