mirror of
https://github.com/danbulant/oxc
synced 2026-05-25 12:51:57 +00:00
Previously:
```rs
let ix = control_flow!(|self, cfg| cfg.current_node_ix);
```
after this PR:
```rs
let ix = control_flow!(self, |cfg| cfg.current_node_ix);
```
It expands to:
```rs
let ix = if let Some(ref mut cfg) = self.cfg {
cfg.current_node_ix
} else {
Default::default()
};
```
So rationale for this change is that it makes it clearer that `self` is passed *in* and `cfg` comes *out* into the "closure".
|
||
|---|---|---|
| .. | ||
| checker | ||
| class | ||
| jsdoc | ||
| module_record | ||
| binder.rs | ||
| builder.rs | ||
| diagnostics.rs | ||
| dot.rs | ||
| label.rs | ||
| lib.rs | ||
| node.rs | ||
| reference.rs | ||
| scope.rs | ||
| symbol.rs | ||