UNPKG

@specs-feup/clava

Version:

A C/C++ source-to-source compiler written in Typescript

20 lines 536 B
import CfgNodeData from "../CfgNodeData.js"; import CfgNodeType from "../CfgNodeType.js"; export default class SwitchData extends CfgNodeData { constructor($stmt, id) { super(CfgNodeType.SWITCH, $stmt, id); } get switch() { return this.nodeStmt; } toString() { if (this.switch === undefined) { return super.toString(); } return "switch(" + this.switch.condition.code + ")"; } isBranch() { return true; } } //# sourceMappingURL=SwitchData.js.map