JS: Add DataFlow::Node.getLocation

This commit is contained in:
Tom Hvitved
2024-03-12 11:08:18 +01:00
parent 35a8e7cbf0
commit 16cef92106
22 changed files with 235 additions and 97 deletions

View File

@@ -356,9 +356,7 @@ class ControlFlowNode extends @cfg_node, Locatable, NodeInStmtContainer {
* A synthetic CFG node that does not correspond to a statement or expression;
* examples include guard nodes and entry/exit nodes.
*/
class SyntheticControlFlowNode extends @synthetic_cfg_node, ControlFlowNode {
override Location getLocation() { hasLocation(this, result) }
}
class SyntheticControlFlowNode extends @synthetic_cfg_node, ControlFlowNode { }
/** A synthetic CFG node marking the entry point of a function or toplevel script. */
class ControlFlowEntryNode extends SyntheticControlFlowNode, @entry_node {