UNPKG

@eagleoutice/flowr

Version:

Static Dataflow Analyzer and Program Slicer for the R Programming Language

21 lines (20 loc) 937 B
import type { DataflowGraph } from './graph/graph'; import type { NodeId } from '../r-bridge/lang-4.x/ast/model/processing/node-id'; export type DataflowGraphClusters = DataflowGraphCluster[]; export interface DataflowGraphCluster { /** * The node which started the cluster, * as this is theoretically picked random, there are just two guarantees you can rely on: * * 1. The node is part of the `members` as well * 2. At one point during the clustering, the node wsa considered as a starting point * * In general, this is more of a debugging aid/representative of the cluster. */ readonly startNode: NodeId; /** All nodes that are part of this cluster */ readonly members: readonly NodeId[]; /** If the cluster contains unknown side effects */ readonly hasUnknownSideEffects: boolean; } export declare function findAllClusters(graph: DataflowGraph): DataflowGraphClusters;