Get the elements of a basic block vertex, i.e., the vertices that are part of this block, only connected by FDs, vertices should never occur in multiple bbs.
Get the type of the given vertex.
const vertex: CfgVertex = CfgVertex.makeExpr('node-1')
console.log(CfgVertex.getType(vertex)); // Output: CfgVertexType.Expression
Check whether the given vertex is a basic block vertex.
Check whether the given vertex is an expression vertex.
Check whether the given vertex is an end marker vertex.
Check whether the given vertex is a statement vertex.
Create a new basic block vertex with the given id, elements, children, and call targets.
the id of the vertex, which should directly relate to the AST node
the vertices that are part of this block, only connected by FDs, vertices should never occur in multiple bbs
A convenience function to create a new marker vertex with a canonical id (CfgVertex#toExitId|toExitId()) based on the given id and the given id as root id.
Create a new expression vertex with the given id, children, call targets, and markers.
A convenience function to create a new expression vertex with a canonical end marker (CfgVertex#toExitId|toExitId()) based on the given id and the given id as root id for the end marker.
A convenience function to create a new vertex which is either a statement or an expression.
Create a new marker vertex with the given id, root id, children, and call targets.
Create a new statement vertex with the given id, children, call targets, and markers.
A convenience function to create a new statement vertex with a canonical end marker (CfgVertex#toExitId|toExitId()) based on the given id and the given id as root id for the end marker.
Map the call targets of a statement or expression vertex, which links all targets of this call, to new call targets using the given mapping function.
Sets in-place Set the elements of a basic block vertex, i.e., the vertices that are part of this block, only connected by FDs, vertices should never occur in multiple bbs.
Sets in-place Set the call targets of a statement or expression vertex, which links all targets of this call.
Sets in-place Set the ids of the end-markers attached to this vertex, which should directly relate to the AST nodes of the end markers.
Sets in-place Set the ids of the mid-markers attached to this vertex, which should directly relate to the AST nodes of the mid markers.
Convert the given vertex type to a string for easier debugging and visualization.
Unpack the root id of a marker vertex, i.e., get the root id stored in the vertex or derive it from the canonical id if it is not explicitly stored.
Helper object for CfgVertex - a vertex in the ControlFlowGraph that may have markers attached to it (e.g., for function calls).