Skip to content

Commit

Permalink
remove edges before nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
Stevengre committed Nov 26, 2024
1 parent 5c76cfc commit c0dcd30
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pyk/src/pyk/kcfg/kcfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -760,11 +760,12 @@ def create_node(self, cterm: CTerm) -> KCFG.Node:
return node

def remove_node(self, node_id: NodeIdLike) -> None:
self.remove_edges_around(node_id)

node_id = self._resolve(node_id)
self._nodes.pop(node_id)
self._deleted_nodes.add(node_id)
self._created_nodes.discard(node_id)
self.remove_edges_around(node_id)

def remove_edges_around(self, node_id: NodeIdLike) -> None:
node_id = self._resolve(node_id)
Expand Down

0 comments on commit c0dcd30

Please sign in to comment.