Remove SwitchIntTarget.

It's only passed to `Analysis::apply_switch_int_edge_effect`, and the
existing impls of that method only use the `value` field. So pass that
instead.
This commit is contained in:
Nicholas Nethercote
2025-02-14 13:23:00 +11:00
parent db1ca60470
commit 3b81d9d42d
3 changed files with 10 additions and 18 deletions

View File

@@ -222,7 +222,7 @@ pub trait Analysis<'tcx> {
&mut self,
_data: &mut Self::SwitchIntData,
_state: &mut Self::Domain,
_edge: SwitchIntTarget,
_value: SwitchTargetValue,
) {
unreachable!();
}
@@ -432,10 +432,5 @@ impl EffectIndex {
}
}
pub struct SwitchIntTarget {
pub value: SwitchTargetValue,
pub target: BasicBlock,
}
#[cfg(test)]
mod tests;