Skip to main content

Module prune_unused_labels_hir

Module prune_unused_labels_hir 

Source
Expand description

Removes unused labels from the HIR.

A label terminal whose body block immediately breaks to the label’s fallthrough (with no other predecessors) is effectively a no-op label. This pass merges such label/body/fallthrough triples into a single block.

Analogous to TS PruneUnusedLabelsHIR.ts.

Functions§

prune_unused_labels_hir