@eagleoutice/flowr 2.9.10 → 2.9.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (165) hide show
  1. package/README.md +48 -50
  2. package/abstract-interpretation/absint-visitor.js +2 -1
  3. package/abstract-interpretation/data-frame/mappers/arguments.d.ts +1 -1
  4. package/abstract-interpretation/data-frame/mappers/arguments.js +2 -2
  5. package/abstract-interpretation/domains/set-range-domain.js +1 -1
  6. package/abstract-interpretation/normalized-ast-fold.d.ts +2 -2
  7. package/abstract-interpretation/normalized-ast-fold.js +4 -3
  8. package/benchmark/slicer.js +5 -5
  9. package/benchmark/summarizer/first-phase/process.js +4 -4
  10. package/cli/repl/commands/repl-normalize.js +2 -2
  11. package/cli/repl/core.js +2 -2
  12. package/config.js +1 -1
  13. package/control-flow/control-flow-graph.d.ts +1 -1
  14. package/control-flow/control-flow-graph.js +1 -2
  15. package/control-flow/extract-cfg.js +4 -3
  16. package/dataflow/cluster.js +1 -1
  17. package/dataflow/environments/built-in.d.ts +2 -15
  18. package/dataflow/environments/built-in.js +11 -31
  19. package/dataflow/eval/resolve/alias-tracking.d.ts +1 -1
  20. package/dataflow/eval/resolve/alias-tracking.js +2 -1
  21. package/dataflow/eval/resolve/resolve.js +4 -3
  22. package/dataflow/fn/exceptions-of-function.d.ts +1 -1
  23. package/dataflow/fn/exceptions-of-function.js +2 -1
  24. package/dataflow/graph/call-graph.d.ts +1 -1
  25. package/dataflow/graph/call-graph.js +4 -3
  26. package/dataflow/graph/dataflowgraph-builder.d.ts +1 -1
  27. package/dataflow/graph/dataflowgraph-builder.js +21 -21
  28. package/dataflow/graph/graph.d.ts +4 -4
  29. package/dataflow/graph/graph.js +27 -22
  30. package/dataflow/internal/linker.d.ts +2 -2
  31. package/dataflow/internal/linker.js +10 -9
  32. package/dataflow/internal/process/functions/call/argument/make-argument.d.ts +2 -1
  33. package/dataflow/internal/process/functions/call/argument/make-argument.js +2 -1
  34. package/dataflow/internal/process/functions/call/built-in/built-in-access.d.ts +1 -1
  35. package/dataflow/internal/process/functions/call/built-in/built-in-access.js +2 -1
  36. package/dataflow/internal/process/functions/call/built-in/built-in-apply.js +3 -5
  37. package/dataflow/internal/process/functions/call/built-in/built-in-expression-list.d.ts +1 -1
  38. package/dataflow/internal/process/functions/call/built-in/built-in-expression-list.js +6 -5
  39. package/dataflow/internal/process/functions/call/built-in/built-in-function-definition.d.ts +1 -1
  40. package/dataflow/internal/process/functions/call/built-in/built-in-function-definition.js +3 -2
  41. package/dataflow/internal/process/functions/call/built-in/built-in-if-then-else.js +4 -4
  42. package/dataflow/internal/process/functions/call/built-in/built-in-local.js +3 -3
  43. package/dataflow/internal/process/functions/call/built-in/built-in-replacement.d.ts +1 -1
  44. package/dataflow/internal/process/functions/call/built-in/built-in-replacement.js +2 -1
  45. package/dataflow/internal/process/functions/call/built-in/built-in-s-seven-new-generic.js +3 -3
  46. package/dataflow/internal/process/functions/call/built-in/built-in-s-three-dispatch.js +3 -3
  47. package/dataflow/internal/process/functions/call/common.d.ts +1 -1
  48. package/dataflow/internal/process/functions/call/common.js +43 -35
  49. package/dataflow/internal/process/functions/process-argument.d.ts +1 -1
  50. package/dataflow/internal/process/functions/process-argument.js +3 -3
  51. package/dataflow/internal/process/functions/process-parameter.js +2 -2
  52. package/dataflow/origin/dfg-get-origin.d.ts +1 -1
  53. package/dataflow/origin/dfg-get-origin.js +2 -2
  54. package/documentation/doc-util/doc-types.js +1 -1
  55. package/documentation/wiki-cfg.js +3 -3
  56. package/documentation/wiki-mk/doc-context.d.ts +8 -0
  57. package/documentation/wiki-mk/doc-context.js +4 -0
  58. package/documentation/wiki-normalized-ast.d.ts +1 -1
  59. package/documentation/wiki-normalized-ast.js +9 -6
  60. package/linter/linter-format.d.ts +10 -0
  61. package/linter/linter-format.js +15 -0
  62. package/linter/rules/absolute-path.js +3 -3
  63. package/linter/rules/file-path-validity.js +1 -1
  64. package/package.json +1 -1
  65. package/project/plugins/file-plugins/files/flowr-description-file.d.ts +5 -0
  66. package/project/plugins/file-plugins/files/flowr-description-file.js +8 -0
  67. package/queries/catalog/call-context-query/identify-link-to-last-call-relation.d.ts +1 -1
  68. package/queries/catalog/call-context-query/identify-link-to-last-call-relation.js +4 -5
  69. package/queries/catalog/dependencies-query/dependencies-query-executor.js +2 -1
  70. package/queries/catalog/dependencies-query/dependencies-query-format.js +6 -5
  71. package/queries/catalog/does-call-query/does-call-query-executor.js +3 -3
  72. package/queries/catalog/inspect-exceptions-query/inspect-exception-query-format.d.ts +1 -1
  73. package/queries/catalog/inspect-exceptions-query/inspect-exception-query-format.js +2 -2
  74. package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-format.d.ts +1 -1
  75. package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-format.js +1 -1
  76. package/queries/catalog/inspect-recursion-query/inspect-recursion-query-format.d.ts +1 -1
  77. package/queries/catalog/inspect-recursion-query/inspect-recursion-query-format.js +1 -1
  78. package/queries/query-print.d.ts +1 -1
  79. package/queries/query-print.js +4 -3
  80. package/r-bridge/lang-4.x/ast/model/model.d.ts +151 -4
  81. package/r-bridge/lang-4.x/ast/model/model.js +249 -0
  82. package/r-bridge/lang-4.x/ast/model/nodes/info/r-delimiter.d.ts +11 -1
  83. package/r-bridge/lang-4.x/ast/model/nodes/info/r-delimiter.js +13 -0
  84. package/r-bridge/lang-4.x/ast/model/nodes/r-access.d.ts +19 -1
  85. package/r-bridge/lang-4.x/ast/model/nodes/r-access.js +26 -0
  86. package/r-bridge/lang-4.x/ast/model/nodes/r-argument.d.ts +36 -3
  87. package/r-bridge/lang-4.x/ast/model/nodes/r-argument.js +48 -13
  88. package/r-bridge/lang-4.x/ast/model/nodes/r-binary-op.d.ts +16 -1
  89. package/r-bridge/lang-4.x/ast/model/nodes/r-binary-op.js +21 -0
  90. package/r-bridge/lang-4.x/ast/model/nodes/r-break.d.ts +11 -1
  91. package/r-bridge/lang-4.x/ast/model/nodes/r-break.js +14 -0
  92. package/r-bridge/lang-4.x/ast/model/nodes/r-comment.d.ts +8 -2
  93. package/r-bridge/lang-4.x/ast/model/nodes/r-comment.js +11 -5
  94. package/r-bridge/lang-4.x/ast/model/nodes/r-expression-list.d.ts +23 -1
  95. package/r-bridge/lang-4.x/ast/model/nodes/r-expression-list.js +32 -0
  96. package/r-bridge/lang-4.x/ast/model/nodes/r-for-loop.d.ts +11 -1
  97. package/r-bridge/lang-4.x/ast/model/nodes/r-for-loop.js +14 -0
  98. package/r-bridge/lang-4.x/ast/model/nodes/r-function-call.d.ts +19 -1
  99. package/r-bridge/lang-4.x/ast/model/nodes/r-function-call.js +26 -1
  100. package/r-bridge/lang-4.x/ast/model/nodes/r-function-definition.d.ts +11 -1
  101. package/r-bridge/lang-4.x/ast/model/nodes/r-function-definition.js +14 -0
  102. package/r-bridge/lang-4.x/ast/model/nodes/r-if-then-else.d.ts +11 -1
  103. package/r-bridge/lang-4.x/ast/model/nodes/r-if-then-else.js +14 -0
  104. package/r-bridge/lang-4.x/ast/model/nodes/r-line-directive.d.ts +12 -2
  105. package/r-bridge/lang-4.x/ast/model/nodes/r-line-directive.js +14 -0
  106. package/r-bridge/lang-4.x/ast/model/nodes/r-logical.d.ts +20 -2
  107. package/r-bridge/lang-4.x/ast/model/nodes/r-logical.js +26 -0
  108. package/r-bridge/lang-4.x/ast/model/nodes/r-next.d.ts +12 -2
  109. package/r-bridge/lang-4.x/ast/model/nodes/r-next.js +14 -0
  110. package/r-bridge/lang-4.x/ast/model/nodes/r-number.d.ts +8 -2
  111. package/r-bridge/lang-4.x/ast/model/nodes/r-number.js +11 -5
  112. package/r-bridge/lang-4.x/ast/model/nodes/r-parameter.d.ts +17 -1
  113. package/r-bridge/lang-4.x/ast/model/nodes/r-parameter.js +22 -0
  114. package/r-bridge/lang-4.x/ast/model/nodes/r-pipe.d.ts +16 -1
  115. package/r-bridge/lang-4.x/ast/model/nodes/r-pipe.js +22 -0
  116. package/r-bridge/lang-4.x/ast/model/nodes/r-project.d.ts +45 -8
  117. package/r-bridge/lang-4.x/ast/model/nodes/r-project.js +57 -16
  118. package/r-bridge/lang-4.x/ast/model/nodes/r-repeat-loop.d.ts +12 -2
  119. package/r-bridge/lang-4.x/ast/model/nodes/r-repeat-loop.js +14 -0
  120. package/r-bridge/lang-4.x/ast/model/nodes/r-string.d.ts +15 -3
  121. package/r-bridge/lang-4.x/ast/model/nodes/r-string.js +21 -6
  122. package/r-bridge/lang-4.x/ast/model/nodes/r-symbol.d.ts +21 -6
  123. package/r-bridge/lang-4.x/ast/model/nodes/r-symbol.js +22 -5
  124. package/r-bridge/lang-4.x/ast/model/nodes/r-unary-op.d.ts +16 -1
  125. package/r-bridge/lang-4.x/ast/model/nodes/r-unary-op.js +21 -0
  126. package/r-bridge/lang-4.x/ast/model/nodes/r-while-loop.d.ts +11 -1
  127. package/r-bridge/lang-4.x/ast/model/nodes/r-while-loop.js +14 -0
  128. package/r-bridge/lang-4.x/ast/model/processing/node-id.d.ts +39 -2
  129. package/r-bridge/lang-4.x/ast/model/processing/node-id.js +52 -9
  130. package/r-bridge/lang-4.x/ast/model/processing/visitor.d.ts +8 -7
  131. package/r-bridge/lang-4.x/ast/model/processing/visitor.js +6 -13
  132. package/r-bridge/lang-4.x/ast/parser/json/parser.d.ts +1 -1
  133. package/r-bridge/lang-4.x/ast/parser/json/parser.js +1 -1
  134. package/r-bridge/lang-4.x/ast/parser/main/internal/expression/normalize-expression.js +4 -2
  135. package/r-bridge/lang-4.x/ast/parser/main/internal/values/normalize-number.js +1 -1
  136. package/r-bridge/lang-4.x/ast/parser/main/internal/values/normalize-string.js +2 -2
  137. package/r-bridge/lang-4.x/convert-values.d.ts +14 -5
  138. package/r-bridge/lang-4.x/convert-values.js +76 -72
  139. package/r-bridge/lang-4.x/tree-sitter/tree-sitter-normalize.js +2 -2
  140. package/r-bridge/roxygen2/roxygen-parse.js +1 -1
  141. package/r-bridge/shell-executor.js +1 -1
  142. package/reconstruct/auto-select/magic-comments.js +4 -4
  143. package/reconstruct/reconstruct.js +2 -1
  144. package/search/search-executor/search-generators.js +2 -2
  145. package/slicing/criterion/filters/all-variables.js +1 -1
  146. package/slicing/criterion/parse.d.ts +1 -1
  147. package/slicing/criterion/parse.js +5 -3
  148. package/slicing/static/slice-call.d.ts +1 -1
  149. package/slicing/static/slice-call.js +2 -2
  150. package/statistics/features/supported/assignments/assignments.js +2 -2
  151. package/statistics/features/supported/control-flow/control-flow.js +2 -2
  152. package/statistics/features/supported/data-access/data-access.js +4 -3
  153. package/statistics/features/supported/defined-functions/defined-functions.js +9 -8
  154. package/statistics/features/supported/expression-list/statistics-expression-list.js +2 -2
  155. package/statistics/features/supported/loops/loops.js +6 -5
  156. package/statistics/features/supported/used-functions/used-functions.js +2 -2
  157. package/statistics/features/supported/variables/variables.js +8 -8
  158. package/util/mermaid/ast.js +2 -2
  159. package/util/mermaid/cfg.js +3 -4
  160. package/util/mermaid/dfg.d.ts +1 -1
  161. package/util/mermaid/dfg.js +9 -9
  162. package/util/simple-df/dfg-ascii.js +1 -1
  163. package/util/version.js +1 -1
  164. package/r-bridge/lang-4.x/ast/model/collect.d.ts +0 -10
  165. package/r-bridge/lang-4.x/ast/model/collect.js +0 -25
package/README.md CHANGED
@@ -24,7 +24,7 @@ It offers a wide variety of features, for example:
24
24
 
25
25
  ```shell
26
26
  $ docker run -it --rm eagleoutice/flowr # or npm run flowr
27
- flowR repl using flowR v2.9.9, R grammar v14 (tree-sitter engine)
27
+ flowR repl using flowR v2.9.10, R grammar v14 (tree-sitter engine)
28
28
  R> :query @linter "read.csv(\"/root/x.txt\")"
29
29
  ```
30
30
 
@@ -33,19 +33,19 @@ It offers a wide variety of features, for example:
33
33
 
34
34
 
35
35
  ```text
36
- Query: linter (3 ms)
36
+ Query: linter (2 ms)
37
37
  ╰ Deprecated Functions (deprecated-functions):
38
- ╰ Metadata: totalCalls: 0, totalFunctionDefinitions: 0, searchTimeMs: 1, processTimeMs: 0
38
+ ╰ Metadata: totalCalls: 0, totalFunctionDefinitions: 0, searchTimeMs: 0, processTimeMs: 0
39
39
  ╰ File Path Validity (file-path-validity):
40
40
  ╰ certain:
41
41
  ╰ Path `/root/x.txt` at 1.1-23
42
- ╰ Metadata: totalReads: 1, totalUnknown: 0, totalWritesBeforeAlways: 0, totalValid: 0, searchTimeMs: 0, processTimeMs: 0
42
+ ╰ Metadata: totalReads: 1, totalUnknown: 0, totalWritesBeforeAlways: 0, totalValid: 0, searchTimeMs: 1, processTimeMs: 0
43
43
  ╰ Seeded Randomness (seeded-randomness):
44
44
  ╰ Metadata: consumerCalls: 0, callsWithFunctionProducers: 0, callsWithAssignmentProducers: 0, callsWithNonConstantProducers: 0, callsWithOtherBranchProducers: 0, searchTimeMs: 0, processTimeMs: 0
45
45
  ╰ Absolute Paths (absolute-file-paths):
46
46
  ╰ certain:
47
47
  ╰ Path `/root/x.txt` at 1.1-23
48
- ╰ Metadata: totalConsidered: 1, totalUnknown: 0, searchTimeMs: 1, processTimeMs: 0
48
+ ╰ Metadata: totalConsidered: 1, totalUnknown: 0, searchTimeMs: 0, processTimeMs: 0
49
49
  ╰ Unused Definitions (unused-definitions):
50
50
  ╰ Metadata: totalConsidered: 0, searchTimeMs: 0, processTimeMs: 0
51
51
  ╰ Naming Convention (naming-convention):
@@ -53,12 +53,12 @@ It offers a wide variety of features, for example:
53
53
  ╰ Network Functions (network-functions):
54
54
  ╰ Metadata: totalCalls: 0, totalFunctionDefinitions: 0, searchTimeMs: 0, processTimeMs: 0
55
55
  ╰ Dataframe Access Validation (dataframe-access-validation):
56
- ╰ Metadata: numOperations: 0, numAccesses: 0, totalAccessed: 0, searchTimeMs: 0, processTimeMs: 0
56
+ ╰ Metadata: numOperations: 0, numAccesses: 0, totalAccessed: 0, searchTimeMs: 0, processTimeMs: 1
57
57
  ╰ Dead Code (dead-code):
58
- ╰ Metadata: consideredNodes: 5, searchTimeMs: 1, processTimeMs: 0
58
+ ╰ Metadata: consideredNodes: 5, searchTimeMs: 0, processTimeMs: 0
59
59
  ╰ Useless Loops (useless-loop):
60
60
  ╰ Metadata: numOfUselessLoops: 0, searchTimeMs: 0, processTimeMs: 0
61
- All queries together required ≈3 ms (1ms accuracy, total 4 ms)
61
+ All queries together required ≈2 ms (1ms accuracy, total 3 ms)
62
62
  ```
63
63
 
64
64
 
@@ -86,9 +86,9 @@ It offers a wide variety of features, for example:
86
86
     ╰ **File Path Validity** (file-path-validity):\
87
87
         ╰ certain:\
88
88
             ╰ Path `/root/x.txt` at 1.1-23\
89
- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>totalReads: 1, totalUnknown: 0, totalWritesBeforeAlways: 0, totalValid: 0, searchTimeMs: 1, processTimeMs: 0</code>\
89
+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>totalReads: 1, totalUnknown: 0, totalWritesBeforeAlways: 0, totalValid: 0, searchTimeMs: 0, processTimeMs: 0</code>\
90
90
  &nbsp;&nbsp;&nbsp;╰ **Seeded Randomness** (seeded-randomness):\
91
- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>consumerCalls: 0, callsWithFunctionProducers: 0, callsWithAssignmentProducers: 0, callsWithNonConstantProducers: 0, callsWithOtherBranchProducers: 0, searchTimeMs: 0, processTimeMs: 0</code>\
91
+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>consumerCalls: 0, callsWithFunctionProducers: 0, callsWithAssignmentProducers: 0, callsWithNonConstantProducers: 0, callsWithOtherBranchProducers: 0, searchTimeMs: 1, processTimeMs: 0</code>\
92
92
  &nbsp;&nbsp;&nbsp;╰ **Absolute Paths** (absolute-file-paths):\
93
93
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ certain:\
94
94
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ Path `/root/x.txt` at 1.1-23\
@@ -100,16 +100,16 @@ It offers a wide variety of features, for example:
100
100
  &nbsp;&nbsp;&nbsp;╰ **Network Functions** (network-functions):\
101
101
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>totalCalls: 0, totalFunctionDefinitions: 0, searchTimeMs: 0, processTimeMs: 0</code>\
102
102
  &nbsp;&nbsp;&nbsp;╰ **Dataframe Access Validation** (dataframe-access-validation):\
103
- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>numOperations: 0, numAccesses: 0, totalAccessed: 0, searchTimeMs: 1, processTimeMs: 0</code>\
103
+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>numOperations: 0, numAccesses: 0, totalAccessed: 0, searchTimeMs: 0, processTimeMs: 0</code>\
104
104
  &nbsp;&nbsp;&nbsp;╰ **Dead Code** (dead-code):\
105
- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>consideredNodes: 5, searchTimeMs: 0, processTimeMs: 0</code>\
105
+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>consideredNodes: 5, searchTimeMs: 0, processTimeMs: 1</code>\
106
106
  &nbsp;&nbsp;&nbsp;╰ **Useless Loops** (useless-loop):\
107
107
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;╰ _Metadata_: <code>numOfUselessLoops: 0, searchTimeMs: 0, processTimeMs: 0</code>\
108
108
  _All queries together required ≈3 ms (1ms accuracy, total 3 ms)_
109
109
 
110
110
  <details> <summary style="color:gray">Show Detailed Results as Json</summary>
111
111
 
112
- The analysis required _3.1 ms_ (including parsing and normalization and the query) within the generation environment.
112
+ The analysis required _2.5 ms_ (including parsing and normalization and the query) within the generation environment.
113
113
 
114
114
  In general, the JSON contains the Ids of the nodes in question as they are present in the normalized AST or the dataflow graph of flowR.
115
115
  Please consult the [Interface](https://github.com/flowr-analysis/flowr/wiki/Interface) wiki page for more information on how to get those.
@@ -149,7 +149,7 @@ It offers a wide variety of features, for example:
149
149
  "totalUnknown": 0,
150
150
  "totalWritesBeforeAlways": 0,
151
151
  "totalValid": 0,
152
- "searchTimeMs": 1,
152
+ "searchTimeMs": 0,
153
153
  "processTimeMs": 0
154
154
  }
155
155
  },
@@ -161,7 +161,7 @@ It offers a wide variety of features, for example:
161
161
  "callsWithAssignmentProducers": 0,
162
162
  "callsWithNonConstantProducers": 0,
163
163
  "callsWithOtherBranchProducers": 0,
164
- "searchTimeMs": 0,
164
+ "searchTimeMs": 1,
165
165
  "processTimeMs": 0
166
166
  }
167
167
  },
@@ -217,7 +217,7 @@ It offers a wide variety of features, for example:
217
217
  "numOperations": 0,
218
218
  "numAccesses": 0,
219
219
  "totalAccessed": 0,
220
- "searchTimeMs": 1,
220
+ "searchTimeMs": 0,
221
221
  "processTimeMs": 0
222
222
  }
223
223
  },
@@ -226,7 +226,7 @@ It offers a wide variety of features, for example:
226
226
  ".meta": {
227
227
  "consideredNodes": 5,
228
228
  "searchTimeMs": 0,
229
- "processTimeMs": 0
229
+ "processTimeMs": 1
230
230
  }
231
231
  },
232
232
  "useless-loop": {
@@ -308,7 +308,7 @@ It offers a wide variety of features, for example:
308
308
 
309
309
  ```shell
310
310
  $ docker run -it --rm eagleoutice/flowr # or npm run flowr
311
- flowR repl using flowR v2.9.9, R grammar v14 (tree-sitter engine)
311
+ flowR repl using flowR v2.9.10, R grammar v14 (tree-sitter engine)
312
312
  R> :query @static-slice (11@sum) file://test/testfiles/example.R
313
313
  ```
314
314
 
@@ -322,7 +322,7 @@ It offers a wide variety of features, for example:
322
322
  N <- 10
323
323
  for(i in 1:(N-1)) sum <- sum + i + w
324
324
  sum
325
- All queries together required ≈3 ms (1ms accuracy, total 4 ms)
325
+ All queries together required ≈2 ms (1ms accuracy, total 3 ms)
326
326
  ```
327
327
 
328
328
 
@@ -356,7 +356,7 @@ It offers a wide variety of features, for example:
356
356
 
357
357
 
358
358
  * 🚀 **fast call-graph, data-, and control-flow graphs**\
359
- Within just [<i><span title="This measurement is automatically fetched from the latest benchmark!">112.3 ms</span></i> (as of Feb 9, 2026)](https://flowr-analysis.github.io/flowr/wiki/stats/benchmark),
359
+ Within just [<i><span title="This measurement is automatically fetched from the latest benchmark!">104.5 ms</span></i> (as of Feb 13, 2026)](https://flowr-analysis.github.io/flowr/wiki/stats/benchmark),
360
360
  _flowR_ can analyze the data- and control-flow of the average real-world R&nbsp;script. See the [benchmarks](https://flowr-analysis.github.io/flowr/wiki/stats/benchmark) for more information,
361
361
  and consult the [wiki pages](https://github.com/flowr-analysis/flowr/wiki/wiki/dataflow-graph) for more details on the [dataflow graphs](https://github.com/flowr-analysis/flowr/wiki/wiki/dataflow-graph) as well as [call graphs](https://github.com/flowr-analysis/flowr/wiki/wiki/dataflow-graph#perspectives-cg).
362
362
 
@@ -392,7 +392,7 @@ It offers a wide variety of features, for example:
392
392
 
393
393
  ```shell
394
394
  $ docker run -it --rm eagleoutice/flowr # or npm run flowr
395
- flowR repl using flowR v2.9.9, R grammar v14 (tree-sitter engine)
395
+ flowR repl using flowR v2.9.10, R grammar v14 (tree-sitter engine)
396
396
  R> :dataflow* test/testfiles/example.R
397
397
  ```
398
398
 
@@ -485,9 +485,6 @@ It offers a wide variety of features, for example:
485
485
  (19)
486
486
  *6.13*
487
487
  (18)`"]]
488
- built-in:_["`Built-In:
489
- (`"]
490
- style built-in:_ stroke:gray,fill:gray,stroke-width:2px,opacity:.8;
491
488
  20[["`#91;RBinaryOp#93; #58;
492
489
  (20)
493
490
  *6.11-17*
@@ -505,6 +502,9 @@ It offers a wide variety of features, for example:
505
502
  (26, :may:36+)
506
503
  *7.10-16*
507
504
  (24, 25)`"]]
505
+ built-in:_["`Built-In:
506
+ #43;`"]
507
+ style built-in:_ stroke:gray,fill:gray,stroke-width:2px,opacity:.8;
508
508
  27(["`#91;RSymbol#93; w
509
509
  (27, :may:36+)
510
510
  *7.20*`"])
@@ -613,96 +613,94 @@ It offers a wide variety of features, for example:
613
613
  18 -.->|"reads, calls"| built-in:-
614
614
  linkStyle 24 stroke:gray;
615
615
  19 -->|"returns, argument"| 18
616
- 19 -.->|"reads"| built-in:_
617
- linkStyle 26 stroke:gray;
618
616
  20 -->|"reads, argument"| 13
619
617
  20 -->|"reads, argument"| 19
620
618
  20 -.->|"reads, calls"| built-in::
621
- linkStyle 29 stroke:gray;
619
+ linkStyle 28 stroke:gray;
622
620
  24 -->|"reads"| 0
623
621
  24 -->|"reads"| 23
624
622
  24 -->|"CD-True"| 36
625
- linkStyle 32 stroke:gray,color:gray;
623
+ linkStyle 31 stroke:gray,color:gray;
626
624
  25 -->|"reads"| 12
627
625
  25 -->|"CD-True"| 36
628
- linkStyle 34 stroke:gray,color:gray;
626
+ linkStyle 33 stroke:gray,color:gray;
629
627
  26 -->|"reads, argument"| 24
630
628
  26 -->|"reads, argument"| 25
631
629
  26 -.->|"reads, calls"| built-in:_
632
- linkStyle 37 stroke:gray;
630
+ linkStyle 36 stroke:gray;
633
631
  26 -->|"CD-True"| 36
634
- linkStyle 38 stroke:gray,color:gray;
632
+ linkStyle 37 stroke:gray,color:gray;
635
633
  27 -->|"reads"| 6
636
634
  27 -->|"CD-True"| 36
637
- linkStyle 40 stroke:gray,color:gray;
635
+ linkStyle 39 stroke:gray,color:gray;
638
636
  28 -->|"reads, argument"| 26
639
637
  28 -->|"reads, argument"| 27
640
638
  28 -.->|"reads, calls"| built-in:_
641
- linkStyle 43 stroke:gray;
639
+ linkStyle 42 stroke:gray;
642
640
  28 -->|"CD-True"| 36
643
- linkStyle 44 stroke:gray,color:gray;
641
+ linkStyle 43 stroke:gray,color:gray;
644
642
  23 -->|"defined-by"| 28
645
643
  23 -->|"defined-by"| 29
646
644
  23 -->|"CD-True"| 36
647
- linkStyle 47 stroke:gray,color:gray;
645
+ linkStyle 46 stroke:gray,color:gray;
648
646
  29 -->|"reads, argument"| 28
649
647
  29 -->|"returns, argument"| 23
650
648
  29 -.->|"reads, calls"| built-in:_-
651
- linkStyle 50 stroke:gray;
649
+ linkStyle 49 stroke:gray;
652
650
  29 -->|"CD-True"| 36
653
- linkStyle 51 stroke:gray,color:gray;
651
+ linkStyle 50 stroke:gray,color:gray;
654
652
  31 -->|"reads"| 3
655
653
  31 -->|"reads"| 30
656
654
  31 -->|"CD-True"| 36
657
- linkStyle 54 stroke:gray,color:gray;
655
+ linkStyle 53 stroke:gray,color:gray;
658
656
  32 -->|"reads"| 12
659
657
  32 -->|"CD-True"| 36
660
- linkStyle 56 stroke:gray,color:gray;
658
+ linkStyle 55 stroke:gray,color:gray;
661
659
  33 -->|"reads, argument"| 31
662
660
  33 -->|"reads, argument"| 32
663
661
  33 -.->|"reads, calls"| built-in:_
664
- linkStyle 59 stroke:gray;
662
+ linkStyle 58 stroke:gray;
665
663
  33 -->|"CD-True"| 36
666
- linkStyle 60 stroke:gray,color:gray;
664
+ linkStyle 59 stroke:gray,color:gray;
667
665
  30 -->|"defined-by"| 33
668
666
  30 -->|"defined-by"| 34
669
667
  30 -->|"CD-True"| 36
670
- linkStyle 63 stroke:gray,color:gray;
668
+ linkStyle 62 stroke:gray,color:gray;
671
669
  34 -->|"reads, argument"| 33
672
670
  34 -->|"returns, argument"| 30
673
671
  34 -.->|"reads, calls"| built-in:_-
674
- linkStyle 66 stroke:gray;
672
+ linkStyle 65 stroke:gray;
675
673
  34 -->|"CD-True"| 36
676
- linkStyle 67 stroke:gray,color:gray;
674
+ linkStyle 66 stroke:gray,color:gray;
677
675
  35 -->|"argument"| 29
678
676
  35 -->|"returns, argument"| 34
679
677
  35 -.->|"reads, calls"| built-in:_
680
- linkStyle 70 stroke:gray;
678
+ linkStyle 69 stroke:gray;
681
679
  35 -->|"CD-True"| 36
682
- linkStyle 71 stroke:gray,color:gray;
680
+ linkStyle 70 stroke:gray,color:gray;
683
681
  36 -->|"argument"| 12
684
682
  36 -->|"reads, argument"| 20
685
683
  36 -->|"argument, non-standard-evaluation"| 35
686
684
  36 -.->|"reads, calls"| built-in:for
687
- linkStyle 75 stroke:gray;
685
+ linkStyle 74 stroke:gray;
688
686
  40 -->|"reads"| 0
689
687
  40 -->|"reads"| 23
690
688
  44 -->|"argument"| 38
691
689
  44 -->|"reads, argument"| 40
692
690
  44 -->|"argument"| 42
693
691
  44 -.->|"reads, calls"| built-in:cat
694
- linkStyle 81 stroke:gray;
692
+ linkStyle 80 stroke:gray;
695
693
  48 -->|"reads"| 3
696
694
  48 -->|"reads"| 30
697
695
  52 -->|"argument"| 46
698
696
  52 -->|"reads, argument"| 48
699
697
  52 -->|"argument"| 50
700
698
  52 -.->|"reads, calls"| built-in:cat
701
- linkStyle 87 stroke:gray;
699
+ linkStyle 86 stroke:gray;
702
700
  ```
703
701
 
704
702
 
705
- (The analysis required _1.9 ms_ (including parse and normalize, using the [tree-sitter](https://github.com/flowr-analysis/flowr/wiki/Engines) engine) within the generation environment.)
703
+ (The analysis required _2.2 ms_ (including parse and normalize, using the [tree-sitter](https://github.com/flowr-analysis/flowr/wiki/Engines) engine) within the generation environment.)
706
704
 
707
705
 
708
706
 
@@ -6,6 +6,7 @@ const semantic_cfg_guided_visitor_1 = require("../control-flow/semantic-cfg-guid
6
6
  const built_in_1 = require("../dataflow/environments/built-in");
7
7
  const vertex_1 = require("../dataflow/graph/vertex");
8
8
  const dfg_get_origin_1 = require("../dataflow/origin/dfg-get-origin");
9
+ const model_1 = require("../r-bridge/lang-4.x/ast/model/model");
9
10
  const r_function_call_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-function-call");
10
11
  const type_1 = require("../r-bridge/lang-4.x/ast/model/type");
11
12
  const assert_1 = require("../util/assert");
@@ -284,7 +285,7 @@ class AbstractInterpretationVisitor extends semantic_cfg_guided_visitor_1.Semant
284
285
  return false;
285
286
  }
286
287
  const node = this.getNormalizedAst(nodeId);
287
- if (node?.type === type_1.RType.ForLoop || node?.type === type_1.RType.WhileLoop || node?.type === type_1.RType.RepeatLoop) {
288
+ if (model_1.RLoopConstructs.is(node)) {
288
289
  return true;
289
290
  }
290
291
  const dataflowVertex = this.getDataflowGraph(nodeId);
@@ -1,6 +1,6 @@
1
1
  import type { ResolveInfo } from '../../../dataflow/eval/resolve/alias-tracking';
2
2
  import type { DataflowGraph } from '../../../dataflow/graph/graph';
3
- import type { RNode } from '../../../r-bridge/lang-4.x/ast/model/model';
3
+ import { RNode } from '../../../r-bridge/lang-4.x/ast/model/model';
4
4
  import type { RArgument } from '../../../r-bridge/lang-4.x/ast/model/nodes/r-argument';
5
5
  import { type RFunctionArgument, type RFunctionCall, EmptyArgument } from '../../../r-bridge/lang-4.x/ast/model/nodes/r-function-call';
6
6
  import type { RSymbol } from '../../../r-bridge/lang-4.x/ast/model/nodes/r-symbol';
@@ -15,8 +15,8 @@ exports.isValidColName = isValidColName;
15
15
  exports.parseRequestContent = parseRequestContent;
16
16
  const vertex_1 = require("../../../dataflow/graph/vertex");
17
17
  const make_argument_1 = require("../../../dataflow/internal/process/functions/call/argument/make-argument");
18
+ const model_1 = require("../../../r-bridge/lang-4.x/ast/model/model");
18
19
  const r_function_call_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-function-call");
19
- const visitor_1 = require("../../../r-bridge/lang-4.x/ast/model/processing/visitor");
20
20
  const type_1 = require("../../../r-bridge/lang-4.x/ast/model/type");
21
21
  const convert_values_1 = require("../../../r-bridge/lang-4.x/convert-values");
22
22
  const assert_1 = require("../../../util/assert");
@@ -133,7 +133,7 @@ function getUnresolvedSymbolsInExpression(expression, dfg) {
133
133
  return [];
134
134
  }
135
135
  const unresolvedSymbols = [];
136
- (0, visitor_1.visitAst)(expression, node => {
136
+ model_1.RNode.visitAst(expression, node => {
137
137
  if (node.type === type_1.RType.Symbol) {
138
138
  const vertex = dfg.get(node.info.id);
139
139
  if ((0, vertex_1.isUseVertex)(vertex?.[0]) && vertex[1].size === 0) {
@@ -61,7 +61,7 @@ class SetRangeDomain extends abstract_domain_1.AbstractDomain {
61
61
  if (this.value === lattice_1.Bottom) {
62
62
  return lattice_1.Bottom;
63
63
  }
64
- else if (this.value.range == lattice_1.Top) {
64
+ else if (this.value.range === lattice_1.Top) {
65
65
  return lattice_1.Top;
66
66
  }
67
67
  return this.value.min.union(this.value.range);
@@ -12,7 +12,7 @@ import type { RPipe } from '../r-bridge/lang-4.x/ast/model/nodes/r-pipe';
12
12
  import type { RUnaryOp } from '../r-bridge/lang-4.x/ast/model/nodes/r-unary-op';
13
13
  import type { RParameter } from '../r-bridge/lang-4.x/ast/model/nodes/r-parameter';
14
14
  import type { RArgument } from '../r-bridge/lang-4.x/ast/model/nodes/r-argument';
15
- import type { RAccess } from '../r-bridge/lang-4.x/ast/model/nodes/r-access';
15
+ import { RAccess } from '../r-bridge/lang-4.x/ast/model/nodes/r-access';
16
16
  import type { RLogical } from '../r-bridge/lang-4.x/ast/model/nodes/r-logical';
17
17
  import type { RBreak } from '../r-bridge/lang-4.x/ast/model/nodes/r-break';
18
18
  import type { RComment } from '../r-bridge/lang-4.x/ast/model/nodes/r-comment';
@@ -21,7 +21,7 @@ import type { RNumber } from '../r-bridge/lang-4.x/ast/model/nodes/r-number';
21
21
  import type { RLineDirective } from '../r-bridge/lang-4.x/ast/model/nodes/r-line-directive';
22
22
  import type { RString } from '../r-bridge/lang-4.x/ast/model/nodes/r-string';
23
23
  import type { RSymbol } from '../r-bridge/lang-4.x/ast/model/nodes/r-symbol';
24
- import type { RProject } from '../r-bridge/lang-4.x/ast/model/nodes/r-project';
24
+ import { RProject } from '../r-bridge/lang-4.x/ast/model/nodes/r-project';
25
25
  type FoldOfType<T extends RType, Returns = void, Info = NoInfo> = (node: Extract<RNode<Info>, {
26
26
  type: T;
27
27
  }>) => Returns;
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.DefaultNormalizedAstFold = void 0;
4
4
  const r_function_call_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-function-call");
5
5
  const type_1 = require("../r-bridge/lang-4.x/ast/model/type");
6
+ const r_access_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-access");
6
7
  const r_project_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-project");
7
8
  /**
8
9
  * Default implementation of a fold over the normalized AST (using the classic fold traversal).
@@ -65,12 +66,12 @@ class DefaultNormalizedAstFold {
65
66
  if (Array.isArray(nodes)) {
66
67
  const n = nodes;
67
68
  return this.concatAll(n.filter(n => n && n !== r_function_call_1.EmptyArgument)
68
- .map(node => (0, r_project_1.isRProject)(node) ?
69
+ .map(node => r_project_1.RProject.is(node) ?
69
70
  this.concatAll(node.files.map(f => this.foldSingle(f.root))) :
70
71
  this.foldSingle(node)));
71
72
  }
72
73
  else if (nodes) {
73
- if ((0, r_project_1.isRProject)(nodes)) {
74
+ if (r_project_1.RProject.is(nodes)) {
74
75
  return this.concatAll(nodes.files.map(f => this.foldSingle(f.root)));
75
76
  }
76
77
  return this.foldSingle(nodes);
@@ -87,7 +88,7 @@ class DefaultNormalizedAstFold {
87
88
  }
88
89
  foldRAccess(access) {
89
90
  let accessed = this.foldSingle(access.accessed);
90
- if (access.operator === '[' || access.operator === '[[') {
91
+ if (r_access_1.RAccess.isIndex(access)) {
91
92
  accessed = this.concat(accessed, this.fold(access.access));
92
93
  }
93
94
  return accessed;
@@ -16,8 +16,6 @@ const strings_1 = require("../util/text/strings");
16
16
  const default_pipelines_1 = require("../core/steps/pipeline/default-pipelines");
17
17
  const retriever_1 = require("../r-bridge/retriever");
18
18
  const collect_all_1 = require("../slicing/criterion/collect-all");
19
- const type_1 = require("../r-bridge/lang-4.x/ast/model/type");
20
- const visitor_1 = require("../r-bridge/lang-4.x/ast/model/processing/visitor");
21
19
  const size_of_1 = require("./stats/size-of");
22
20
  const shell_1 = require("../r-bridge/shell");
23
21
  const tree_sitter_types_1 = require("../r-bridge/lang-4.x/tree-sitter/tree-sitter-types");
@@ -31,6 +29,8 @@ const lattice_1 = require("../abstract-interpretation/domains/lattice");
31
29
  const set_range_domain_1 = require("../abstract-interpretation/domains/set-range-domain");
32
30
  const fs_1 = __importDefault(require("fs"));
33
31
  const flowr_analyzer_context_1 = require("../project/context/flowr-analyzer-context");
32
+ const r_project_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-project");
33
+ const r_comment_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-comment");
34
34
  /**
35
35
  * The logger to be used for benchmarking as a global object.
36
36
  */
@@ -127,9 +127,9 @@ class BenchmarkSlicer {
127
127
  let nodesNoComments = 0;
128
128
  let commentChars = 0;
129
129
  let commentCharsNoWhitespace = 0;
130
- (0, visitor_1.visitAst)(this.normalizedAst.ast.files.map(f => f.root), t => {
130
+ r_project_1.RProject.visitAst(this.normalizedAst.ast, t => {
131
131
  nodes++;
132
- const comments = t.info.adToks?.filter(t => t.type === type_1.RType.Comment);
132
+ const comments = t.info.adToks?.filter(r_comment_1.RComment.is);
133
133
  if (comments && comments.length > 0) {
134
134
  const content = comments.map(c => c.lexeme ?? '').join('');
135
135
  commentChars += content.length;
@@ -271,7 +271,7 @@ class BenchmarkSlicer {
271
271
  stats.numberOfResultingValues++;
272
272
  }
273
273
  }
274
- (0, visitor_1.visitAst)(this.normalizedAst.ast.files.map(file => file.root), node => {
274
+ r_project_1.RProject.visitAst(this.normalizedAst.ast, node => {
275
275
  const operations = inference.getAbstractOperations(node.info.id);
276
276
  const value = inference.getAbstractValue(node.info.id);
277
277
  // Only store per-node information for nodes representing expressions or nodes with abstract values
@@ -50,10 +50,10 @@ const summarizer_1 = require("../../../util/summarizer");
50
50
  const assert_1 = require("../../../util/assert");
51
51
  const shell_1 = require("../../../r-bridge/shell");
52
52
  const retriever_1 = require("../../../r-bridge/retriever");
53
- const visitor_1 = require("../../../r-bridge/lang-4.x/ast/model/processing/visitor");
54
- const type_1 = require("../../../r-bridge/lang-4.x/ast/model/type");
55
53
  const arrays_1 = require("../../../util/collections/arrays");
56
54
  const semantics_1 = require("../../../abstract-interpretation/data-frame/semantics");
55
+ const r_project_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-project");
56
+ const r_comment_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-comment");
57
57
  const tempfile = (() => {
58
58
  let _tempfile = undefined;
59
59
  return () => {
@@ -159,9 +159,9 @@ async function summarizeSlicerStats(stats, report = () => {
159
159
  let numberOfNormalizedTokensNoComments = 0;
160
160
  let commentChars = 0;
161
161
  let commentCharsNoWhitespace = 0;
162
- (0, visitor_1.visitAst)(reParsed.ast.files.map(f => f.root), t => {
162
+ r_project_1.RProject.visitAst(reParsed.ast, t => {
163
163
  numberOfNormalizedTokens++;
164
- const comments = t.info.adToks?.filter(t => t.type === type_1.RType.Comment);
164
+ const comments = t.info.adToks?.filter(r_comment_1.RComment.is);
165
165
  if (comments && comments.length > 0) {
166
166
  const content = comments.map(c => c.lexeme ?? '').join('');
167
167
  commentChars += content.length;
@@ -39,7 +39,7 @@ const ast_1 = require("../../../util/mermaid/ast");
39
39
  const ansi_1 = require("../../../util/text/ansi");
40
40
  const core_1 = require("../core");
41
41
  const defaultmap_1 = require("../../../util/collections/defaultmap");
42
- const visitor_1 = require("../../../r-bridge/lang-4.x/ast/model/processing/visitor");
42
+ const r_project_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-project");
43
43
  function formatInfo(out, type, meta) {
44
44
  return out.formatter.format(`Copied ${type} to clipboard (normalize: ${meta['.meta'].timing + 'ms'}).`, { color: 7 /* Colors.White */, effect: ansi_1.ColorEffect.Foreground, style: 3 /* FontStyles.Italic */ });
45
45
  }
@@ -93,7 +93,7 @@ exports.normalizeHashCommand = {
93
93
  const counts = new defaultmap_1.DefaultMap(() => 0);
94
94
  let total = 0;
95
95
  const files = result.ast.files.length;
96
- (0, visitor_1.visitAst)(result.ast.files.map(f => f.root), n => {
96
+ r_project_1.RProject.visitAst(result.ast, n => {
97
97
  counts.set(n.type, counts.get(n.type) + 1);
98
98
  total++;
99
99
  });
package/cli/repl/core.js CHANGED
@@ -110,7 +110,7 @@ function replCompleter(line, config) {
110
110
  function replQueryCompleter(splitLine, startingNewArg, config) {
111
111
  const nonEmpty = splitLine.slice(1).map(s => s.trim()).filter(s => s.length > 0);
112
112
  const queryShorts = Object.keys(query_1.SupportedQueries).map(q => `@${q}`).concat(['help']);
113
- if (nonEmpty.length == 0 || (nonEmpty.length == 1 && queryShorts.some(q => q.startsWith(nonEmpty[0]) && nonEmpty[0] !== q && !startingNewArg))) {
113
+ if (nonEmpty.length === 0 || (nonEmpty.length === 1 && queryShorts.some(q => q.startsWith(nonEmpty[0]) && nonEmpty[0] !== q && !startingNewArg))) {
114
114
  return { completions: queryShorts.map(q => `${q} `) };
115
115
  }
116
116
  else {
@@ -141,7 +141,7 @@ function makeDefaultReplReadline(config) {
141
141
  */
142
142
  function handleString(code) {
143
143
  return {
144
- rCode: code.length == 0 ? undefined : (0, strings_1.startAndEndsWith)(code, '"') ? JSON.parse(code) : code,
144
+ rCode: code.length === 0 ? undefined : (0, strings_1.startAndEndsWith)(code, '"') ? JSON.parse(code) : code,
145
145
  remaining: []
146
146
  };
147
147
  }
package/config.js CHANGED
@@ -213,7 +213,7 @@ function getEngineConfig(config, engine) {
213
213
  return defaultEngineConfigs[engine];
214
214
  }
215
215
  else {
216
- return engines.find(e => e.type == engine);
216
+ return engines.find(e => e.type === engine);
217
217
  }
218
218
  }
219
219
  function loadConfigFromFile(configFile, workingDirectory) {
@@ -1,4 +1,4 @@
1
- import type { NodeId } from '../r-bridge/lang-4.x/ast/model/processing/node-id';
1
+ import { NodeId } from '../r-bridge/lang-4.x/ast/model/processing/node-id';
2
2
  import type { MergeableRecord } from '../util/objects';
3
3
  import { RFalse, RTrue } from '../r-bridge/lang-4.x/convert-values';
4
4
  /**
@@ -343,7 +343,7 @@ exports.CfgVertex = {
343
343
  */
344
344
  fromExitId(exitId) {
345
345
  if (typeof exitId === 'string' && exitId.endsWith('-e')) {
346
- return (0, node_id_1.normalizeIdToNumberIfPossible)(exitId.slice(0, -2));
346
+ return node_id_1.NodeId.normalize(exitId.slice(0, -2));
347
347
  }
348
348
  else {
349
349
  return exitId;
@@ -564,7 +564,6 @@ class ControlFlowGraph {
564
564
  */
565
565
  addVertex(vertex, rootVertex = true) {
566
566
  const vid = exports.CfgVertex.getId(vertex);
567
- (0, assert_1.guard)(!this.vtxInfos.has(vid), `Node with id ${vid} already exists`);
568
567
  if (exports.CfgVertex.isBlock(vertex)) {
569
568
  this._mayBB = true;
570
569
  const elems = exports.CfgVertex.getBasicBlockElements(vertex);
@@ -6,6 +6,7 @@ exports.extractCfgQuick = extractCfgQuick;
6
6
  exports.getCallsInCfg = getCallsInCfg;
7
7
  exports.cfg2quads = cfg2quads;
8
8
  const quads_1 = require("../util/quads");
9
+ const r_function_definition_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-function-definition");
9
10
  const r_function_call_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-function-call");
10
11
  const linker_1 = require("../dataflow/internal/linker");
11
12
  const vertex_1 = require("../dataflow/graph/vertex");
@@ -14,13 +15,13 @@ const cfg_simplification_1 = require("./cfg-simplification");
14
15
  const assert_1 = require("../util/assert");
15
16
  const built_in_1 = require("../dataflow/environments/built-in");
16
17
  const stateful_fold_1 = require("../r-bridge/lang-4.x/ast/model/processing/stateful-fold");
17
- const type_1 = require("../r-bridge/lang-4.x/ast/model/type");
18
+ const model_1 = require("../r-bridge/lang-4.x/ast/model/model");
18
19
  const cfgFolds = {
19
20
  down: (n, down) => {
20
- if (n.type === type_1.RType.FunctionDefinition) {
21
+ if (r_function_definition_1.RFunctionDefinition.is(n)) {
21
22
  return [down[0], true];
22
23
  }
23
- else if (n.type === type_1.RType.ForLoop || n.type === type_1.RType.WhileLoop || n.type === type_1.RType.RepeatLoop) {
24
+ else if (model_1.RLoopConstructs.is(n)) {
24
25
  return [true, down[1]];
25
26
  }
26
27
  return down;
@@ -37,7 +37,7 @@ function makeCluster(graph, from, notReached) {
37
37
  // cluster adjacent edges
38
38
  for (const [dest, e] of [...graph.outgoingEdges(from) ?? [], ...graph.ingoingEdges(from) ?? []]) {
39
39
  // don't cluster for function content if it isn't returned
40
- if (edge_1.DfEdge.doesNotIncludeType(e, edge_1.EdgeType.Returns) && info.onlyBuiltin && info.name == '{') {
40
+ if (edge_1.DfEdge.doesNotIncludeType(e, edge_1.EdgeType.Returns) && info.onlyBuiltin && info.name === '{') {
41
41
  continue;
42
42
  }
43
43
  if (notReached.delete(dest)) {
@@ -16,8 +16,8 @@ import { processExpressionList } from '../internal/process/functions/call/built-
16
16
  import { processGet } from '../internal/process/functions/call/built-in/built-in-get';
17
17
  import type { AstIdMap, ParentInformation, RNodeWithParent } from '../../r-bridge/lang-4.x/ast/model/processing/decorate';
18
18
  import { type RFunctionArgument } from '../../r-bridge/lang-4.x/ast/model/nodes/r-function-call';
19
- import type { RSymbol } from '../../r-bridge/lang-4.x/ast/model/nodes/r-symbol';
20
- import type { NodeId } from '../../r-bridge/lang-4.x/ast/model/processing/node-id';
19
+ import { RSymbol } from '../../r-bridge/lang-4.x/ast/model/nodes/r-symbol';
20
+ import { type BuiltIn, NodeId } from '../../r-bridge/lang-4.x/ast/model/processing/node-id';
21
21
  import { processLibrary } from '../internal/process/functions/call/built-in/built-in-library';
22
22
  import { processSourceCall } from '../internal/process/functions/call/built-in/built-in-source';
23
23
  import type { ForceArguments } from '../internal/process/functions/call/common';
@@ -42,19 +42,6 @@ import { processS3Dispatch } from '../internal/process/functions/call/built-in/b
42
42
  import { processRecall } from '../internal/process/functions/call/built-in/built-in-recall';
43
43
  import { processS7NewGeneric } from '../internal/process/functions/call/built-in/built-in-s-seven-new-generic';
44
44
  import { processS7Dispatch } from '../internal/process/functions/call/built-in/built-in-s-seven-dispatch';
45
- export type BuiltIn = `built-in:${string}`;
46
- /**
47
- * Generate a built-in id for the given name
48
- */
49
- export declare function builtInId<T extends string>(name: T): `built-in:${T}`;
50
- /**
51
- * Checks whether the given name is a built-in identifier
52
- */
53
- export declare function isBuiltIn(name: NodeId | string): name is BuiltIn;
54
- /**
55
- * Drops the `built-in:` prefix from the given built-in name
56
- */
57
- export declare function dropBuiltInPrefix<T extends string>(name: `built-in:${T}`): T;
58
45
  export type BuiltInIdentifierProcessor = <OtherInfo>(name: RSymbol<OtherInfo & ParentInformation>, args: readonly RFunctionArgument<OtherInfo & ParentInformation>[], rootId: NodeId, data: DataflowProcessorInformation<OtherInfo & ParentInformation>) => DataflowInformation;
59
46
  export type BuiltInIdentifierProcessorWithConfig<Config> = <OtherInfo>(name: RSymbol<OtherInfo & ParentInformation>, args: readonly RFunctionArgument<OtherInfo & ParentInformation>[], rootId: NodeId, data: DataflowProcessorInformation<OtherInfo & ParentInformation>, config: Config) => DataflowInformation;
60
47
  export interface BuiltInIdentifierDefinition extends IdentifierReference {