Skip to content

Commit

Permalink
refactor: use from_node in lowering
Browse files Browse the repository at this point in the history
  • Loading branch information
ss2165 committed Dec 11, 2024
1 parent e0827a9 commit 9ce3ab6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hugr-passes/src/lower.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ pub fn lower_ops(
replacements
.into_iter()
.map(|(node, replacement)| {
let subcirc = SiblingSubgraph::try_from_nodes([node], hugr)?;
let subcirc = SiblingSubgraph::from_node(node, hugr);
let rw = subcirc.create_simple_replacement(hugr, replacement)?;
let mut repls = hugr.apply_rewrite(rw)?;
debug_assert_eq!(repls.len(), 1);
Expand Down

0 comments on commit 9ce3ab6

Please sign in to comment.