@eagleoutice/flowr 2.15.9 → 2.16.0

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 (244) hide show
  1. package/README.md +47 -41
  2. package/abstract-interpretation/absint-inference.d.ts +2 -2
  3. package/abstract-interpretation/absint-inference.js +32 -79
  4. package/abstract-interpretation/data-frame/arguments.js +11 -7
  5. package/benchmark/slicer.d.ts +0 -1
  6. package/benchmark/slicer.js +1 -2
  7. package/cli/repl/commands/repl-signature.js +12 -3
  8. package/config.d.ts +5 -1
  9. package/control-flow/cfg-properties.js +0 -22
  10. package/control-flow/happens-before.d.ts +7 -2
  11. package/control-flow/happens-before.js +55 -31
  12. package/control-flow/useless-loop.d.ts +1 -1
  13. package/control-flow/useless-loop.js +29 -42
  14. package/dataflow/environments/apply-kill.js +6 -2
  15. package/dataflow/environments/built-in-config.d.ts +2 -0
  16. package/dataflow/environments/built-in-props.d.ts +16 -1
  17. package/dataflow/environments/built-in-props.js +33 -20
  18. package/dataflow/environments/built-in.d.ts +8 -3
  19. package/dataflow/environments/built-in.js +52 -82
  20. package/dataflow/environments/default-builtin-config.d.ts +551 -21
  21. package/dataflow/environments/default-builtin-config.js +121 -45
  22. package/dataflow/environments/define.d.ts +3 -2
  23. package/dataflow/environments/define.js +4 -3
  24. package/dataflow/environments/deprecation-info.d.ts +45 -0
  25. package/dataflow/environments/deprecation-info.js +13 -0
  26. package/dataflow/environments/environment.d.ts +7 -5
  27. package/dataflow/environments/environment.js +55 -121
  28. package/dataflow/environments/identifier.d.ts +6 -2
  29. package/dataflow/environments/identifier.js +23 -69
  30. package/dataflow/environments/reference-to-maybe.d.ts +9 -0
  31. package/dataflow/environments/reference-to-maybe.js +23 -51
  32. package/dataflow/environments/resolve-by-name.js +37 -76
  33. package/dataflow/eval/resolve/resolve-argument.d.ts +3 -1
  34. package/dataflow/eval/resolve/resolve-argument.js +61 -64
  35. package/dataflow/eval/resolve/resolve-working-directory.d.ts +8 -2
  36. package/dataflow/eval/resolve/resolve-working-directory.js +12 -20
  37. package/dataflow/eval/resolve/resolve.d.ts +4 -0
  38. package/dataflow/eval/resolve/resolve.js +23 -14
  39. package/dataflow/extractor.js +180 -58
  40. package/dataflow/fn/class-declaration.d.ts +8 -13
  41. package/dataflow/fn/class-declaration.js +95 -116
  42. package/dataflow/fn/exceptions-of-function.js +68 -37
  43. package/dataflow/fn/frame-reflection.d.ts +12 -4
  44. package/dataflow/fn/frame-reflection.js +51 -41
  45. package/dataflow/fn/function-props.js +15 -33
  46. package/dataflow/fn/function-semantics.d.ts +11 -3
  47. package/dataflow/fn/function-semantics.js +6 -0
  48. package/dataflow/fn/higher-order-function.d.ts +9 -1
  49. package/dataflow/fn/higher-order-function.js +27 -24
  50. package/dataflow/fn/strict-function.d.ts +13 -0
  51. package/dataflow/fn/strict-function.js +291 -123
  52. package/dataflow/graph/call-graph.d.ts +7 -6
  53. package/dataflow/graph/call-graph.js +35 -46
  54. package/dataflow/graph/graph.d.ts +13 -1
  55. package/dataflow/graph/graph.js +74 -66
  56. package/dataflow/graph/vertex.d.ts +1 -1
  57. package/dataflow/info.d.ts +8 -1
  58. package/dataflow/info.js +24 -30
  59. package/dataflow/internal/control-flow.d.ts +31 -4
  60. package/dataflow/internal/control-flow.js +61 -39
  61. package/dataflow/internal/linker.d.ts +17 -8
  62. package/dataflow/internal/linker.js +286 -213
  63. package/dataflow/internal/process/functions/call/built-in/built-in-ambient-state.d.ts +179 -0
  64. package/dataflow/internal/process/functions/call/built-in/built-in-ambient-state.js +874 -0
  65. package/dataflow/internal/process/functions/call/built-in/built-in-apply.d.ts +3 -1
  66. package/dataflow/internal/process/functions/call/built-in/built-in-apply.js +60 -48
  67. package/dataflow/internal/process/functions/call/built-in/built-in-assignment.d.ts +4 -2
  68. package/dataflow/internal/process/functions/call/built-in/built-in-assignment.js +135 -198
  69. package/dataflow/internal/process/functions/call/built-in/built-in-class-generator.js +7 -9
  70. package/dataflow/internal/process/functions/call/built-in/built-in-envir-utils.d.ts +5 -1
  71. package/dataflow/internal/process/functions/call/built-in/built-in-envir-utils.js +21 -14
  72. package/dataflow/internal/process/functions/call/built-in/built-in-eval.js +14 -4
  73. package/dataflow/internal/process/functions/call/built-in/built-in-expression-list.d.ts +1 -1
  74. package/dataflow/internal/process/functions/call/built-in/built-in-expression-list.js +141 -146
  75. package/dataflow/internal/process/functions/call/built-in/built-in-for-loop.js +56 -24
  76. package/dataflow/internal/process/functions/call/built-in/built-in-function-definition.js +292 -253
  77. package/dataflow/internal/process/functions/call/built-in/built-in-get.d.ts +1 -1
  78. package/dataflow/internal/process/functions/call/built-in/built-in-get.js +30 -32
  79. package/dataflow/internal/process/functions/call/built-in/built-in-if-then-else.js +68 -67
  80. package/dataflow/internal/process/functions/call/built-in/built-in-library.js +91 -129
  81. package/dataflow/internal/process/functions/call/built-in/built-in-local.d.ts +1 -3
  82. package/dataflow/internal/process/functions/call/built-in/built-in-local.js +16 -12
  83. package/dataflow/internal/process/functions/call/built-in/built-in-quote.d.ts +4 -4
  84. package/dataflow/internal/process/functions/call/built-in/built-in-quote.js +9 -35
  85. package/dataflow/internal/process/functions/call/built-in/built-in-repeat-loop.js +2 -0
  86. package/dataflow/internal/process/functions/call/built-in/built-in-rm.js +8 -3
  87. package/dataflow/internal/process/functions/call/built-in/built-in-s-four.d.ts +5 -3
  88. package/dataflow/internal/process/functions/call/built-in/built-in-s-four.js +13 -31
  89. package/dataflow/internal/process/functions/call/built-in/built-in-s-seven-new-generic.d.ts +1 -1
  90. package/dataflow/internal/process/functions/call/built-in/built-in-s-seven-new-generic.js +42 -119
  91. package/dataflow/internal/process/functions/call/built-in/built-in-s-three-dispatch.d.ts +1 -3
  92. package/dataflow/internal/process/functions/call/built-in/built-in-s-three-dispatch.js +21 -21
  93. package/dataflow/internal/process/functions/call/built-in/built-in-source.d.ts +2 -0
  94. package/dataflow/internal/process/functions/call/built-in/built-in-source.js +93 -102
  95. package/dataflow/internal/process/functions/call/built-in/built-in-try-catch.d.ts +7 -3
  96. package/dataflow/internal/process/functions/call/built-in/built-in-try-catch.js +173 -114
  97. package/dataflow/internal/process/functions/call/built-in/built-in-while-loop.d.ts +1 -3
  98. package/dataflow/internal/process/functions/call/built-in/built-in-while-loop.js +23 -26
  99. package/dataflow/internal/process/functions/call/built-in/built-in-with.d.ts +1 -1
  100. package/dataflow/internal/process/functions/call/built-in/built-in-with.js +34 -9
  101. package/dataflow/internal/process/functions/call/built-in/transitive-side-effects.d.ts +1 -1
  102. package/dataflow/internal/process/functions/call/built-in/transitive-side-effects.js +119 -93
  103. package/dataflow/internal/process/functions/call/common.d.ts +4 -4
  104. package/dataflow/internal/process/functions/call/common.js +49 -71
  105. package/dataflow/internal/process/functions/call/deferred.d.ts +12 -2
  106. package/dataflow/internal/process/functions/call/deferred.js +81 -63
  107. package/dataflow/internal/process/functions/call/known-call-handling.d.ts +4 -2
  108. package/dataflow/internal/process/functions/call/known-call-handling.js +65 -68
  109. package/dataflow/internal/process/functions/call/named-call-handling.d.ts +3 -5
  110. package/dataflow/internal/process/functions/call/named-call-handling.js +48 -19
  111. package/dataflow/internal/process/functions/call/quoted.d.ts +2 -0
  112. package/dataflow/internal/process/functions/call/quoted.js +257 -154
  113. package/dataflow/internal/process/functions/call/unnamed-call-handling.js +17 -38
  114. package/dataflow/internal/process/functions/process-parameter.js +25 -32
  115. package/dataflow/internal/process/process-symbol.js +4 -3
  116. package/dataflow/internal/program-order.d.ts +26 -0
  117. package/dataflow/internal/program-order.js +49 -0
  118. package/documentation/data/faq/faqs.js +3 -3
  119. package/documentation/data/interface/doc-writing-code.js +1 -2
  120. package/documentation/data/server/doc-data-server-messages.js +7 -7
  121. package/documentation/doc-capabilities.js +80 -34
  122. package/documentation/doc-util/doc-query.d.ts +0 -3
  123. package/documentation/doc-util/doc-query.js +4 -3
  124. package/documentation/wiki-analyzer.js +1 -1
  125. package/documentation/wiki-cfg.js +5 -6
  126. package/documentation/wiki-core.js +8 -8
  127. package/documentation/wiki-dataflow-graph.js +10 -11
  128. package/documentation/wiki-interface.js +2 -2
  129. package/documentation/wiki-linting-and-testing.js +3 -3
  130. package/documentation/wiki-overview.js +6 -6
  131. package/documentation/wiki-query.js +9 -101
  132. package/documentation/wiki-setup.js +23 -0
  133. package/documentation/wiki-signature-database.js +1 -1
  134. package/linter/linter-rules.d.ts +18 -9
  135. package/linter/rules/absolute-path.js +63 -87
  136. package/linter/rules/deprecated-functions.d.ts +1 -45
  137. package/linter/rules/deprecated-functions.js +24 -33
  138. package/linter/rules/file-path-validity.d.ts +4 -2
  139. package/linter/rules/file-path-validity.js +114 -80
  140. package/linter/rules/namespace-access.js +21 -33
  141. package/linter/rules/naming-convention.d.ts +1 -1
  142. package/linter/rules/naming-convention.js +60 -48
  143. package/linter/rules/network-functions.js +11 -7
  144. package/linter/rules/no-leaked-credentials.js +15 -18
  145. package/linter/rules/problematic-inputs.d.ts +2 -1
  146. package/linter/rules/problematic-inputs.js +39 -59
  147. package/linter/rules/roxygen-arguments.d.ts +9 -4
  148. package/linter/rules/roxygen-arguments.js +29 -48
  149. package/linter/rules/seeded-randomness.d.ts +7 -4
  150. package/linter/rules/seeded-randomness.js +128 -89
  151. package/linter/rules/stop-with-call-arg.d.ts +4 -2
  152. package/linter/rules/stop-with-call-arg.js +25 -22
  153. package/linter/rules/unclosed-connection.js +31 -24
  154. package/linter/rules/undefined-symbol.d.ts +4 -6
  155. package/linter/rules/undefined-symbol.js +58 -75
  156. package/linter/rules/unescaped-arguments.js +18 -44
  157. package/linter/rules/unused-definition.d.ts +6 -0
  158. package/linter/rules/unused-definition.js +105 -145
  159. package/linter/rules/unused-import.d.ts +3 -0
  160. package/linter/rules/unused-import.js +25 -43
  161. package/package.json +5 -2
  162. package/project/flowr-analyzer.d.ts +2 -0
  163. package/project/flowr-analyzer.js +28 -1
  164. package/project/plugins/file-plugins/files/flowr-jupyter-file.d.ts +2 -2
  165. package/project/plugins/file-plugins/files/flowr-jupyter-file.js +8 -12
  166. package/project/plugins/file-plugins/files/flowr-rda-file.d.ts +0 -2
  167. package/project/plugins/file-plugins/files/flowr-rda-file.js +10 -55
  168. package/project/plugins/file-plugins/files/flowr-rmarkdown-file.d.ts +7 -5
  169. package/project/plugins/file-plugins/files/flowr-rmarkdown-file.js +34 -56
  170. package/project/plugins/file-plugins/flowr-analyzer-file-plugin.js +2 -1
  171. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-sigdb-plugin.js +22 -45
  172. package/project/plugins/project-discovery/flowr-analyzer-project-discovery-plugin.js +2 -2
  173. package/project/sigdb/build.js +4 -0
  174. package/project/sigdb/manifest.d.ts +2 -0
  175. package/project/sigdb/manifest.js +10 -1
  176. package/project/sigdb/reader.js +23 -61
  177. package/project/sigdb/sigdb-download.d.ts +29 -6
  178. package/project/sigdb/sigdb-download.js +212 -64
  179. package/queries/base-query-format.js +1 -2
  180. package/queries/catalog/absint-query/absint-query-format.js +1 -1
  181. package/queries/catalog/call-context-query/cascade-action.d.ts +3 -1
  182. package/queries/catalog/call-context-query/cascade-action.js +2 -0
  183. package/queries/catalog/call-context-query/identify-link-to-last-call-relation.js +3 -0
  184. package/queries/catalog/dataflow-query/dataflow-query-executor.js +2 -2
  185. package/queries/catalog/dataflow-query/dataflow-query-format.d.ts +2 -0
  186. package/queries/catalog/dataflow-query/dataflow-query-format.js +4 -7
  187. package/queries/catalog/dependencies-query/dependencies-query-executor.js +50 -114
  188. package/queries/catalog/dependencies-query/function-info/library-functions.d.ts +5 -9
  189. package/queries/catalog/dependencies-query/function-info/library-functions.js +6 -0
  190. package/queries/catalog/dependencies-query/function-info/read-functions.js +1 -1
  191. package/queries/catalog/dependencies-query/function-info/write-functions.js +7 -3
  192. package/queries/catalog/input-sources-query/simple-input-classifier.d.ts +4 -4
  193. package/queries/catalog/input-sources-query/simple-input-classifier.js +192 -301
  194. package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-executor.js +2 -1
  195. package/queries/catalog/origin-query/origin-query-executor.d.ts +1 -1
  196. package/queries/catalog/origin-query/origin-query-executor.js +2 -2
  197. package/queries/catalog/origin-query/origin-query-format.d.ts +2 -2
  198. package/queries/catalog/origin-query/origin-query-format.js +1 -1
  199. package/queries/query.d.ts +1 -1
  200. package/r-bridge/data/data.d.ts +21 -14
  201. package/r-bridge/data/data.js +28 -20
  202. package/r-bridge/lang-4.x/ast/model/model.d.ts +3 -1
  203. package/r-bridge/lang-4.x/ast/model/model.js +19 -43
  204. package/r-bridge/lang-4.x/ast/model/nodes/r-access.d.ts +1 -0
  205. package/r-bridge/lang-4.x/ast/model/nodes/r-argument.d.ts +3 -0
  206. package/r-bridge/lang-4.x/ast/model/nodes/r-argument.js +5 -12
  207. package/r-bridge/lang-4.x/ast/model/nodes/r-binary-op.d.ts +1 -0
  208. package/r-bridge/lang-4.x/ast/model/nodes/r-break.d.ts +1 -0
  209. package/r-bridge/lang-4.x/ast/model/nodes/r-comment.d.ts +1 -0
  210. package/r-bridge/lang-4.x/ast/model/nodes/r-expression-list.d.ts +1 -0
  211. package/r-bridge/lang-4.x/ast/model/nodes/r-for-loop.d.ts +1 -0
  212. package/r-bridge/lang-4.x/ast/model/nodes/r-function-call.d.ts +1 -0
  213. package/r-bridge/lang-4.x/ast/model/nodes/r-function-definition.d.ts +1 -0
  214. package/r-bridge/lang-4.x/ast/model/nodes/r-if-then-else.d.ts +1 -0
  215. package/r-bridge/lang-4.x/ast/model/nodes/r-line-directive.d.ts +1 -0
  216. package/r-bridge/lang-4.x/ast/model/nodes/r-logical.d.ts +1 -0
  217. package/r-bridge/lang-4.x/ast/model/nodes/r-next.d.ts +1 -0
  218. package/r-bridge/lang-4.x/ast/model/nodes/r-number.d.ts +1 -0
  219. package/r-bridge/lang-4.x/ast/model/nodes/r-parameter.d.ts +1 -0
  220. package/r-bridge/lang-4.x/ast/model/nodes/r-pipe.d.ts +1 -0
  221. package/r-bridge/lang-4.x/ast/model/nodes/r-repeat-loop.d.ts +1 -0
  222. package/r-bridge/lang-4.x/ast/model/nodes/r-string.d.ts +1 -0
  223. package/r-bridge/lang-4.x/ast/model/nodes/r-symbol.d.ts +1 -0
  224. package/r-bridge/lang-4.x/ast/model/nodes/r-unary-op.d.ts +1 -0
  225. package/r-bridge/lang-4.x/ast/model/nodes/r-while-loop.d.ts +1 -0
  226. package/r-bridge/lang-4.x/tree-sitter/tree-sitter-executor.d.ts +2 -2
  227. package/r-bridge/lang-4.x/tree-sitter/tree-sitter-executor.js +11 -2
  228. package/r-bridge/roxygen2/roxygen-parse.js +28 -42
  229. package/r-bridge/shell.js +6 -0
  230. package/search/search-executor/search-enrichers.js +25 -37
  231. package/slicing/static/slice-call.d.ts +4 -3
  232. package/slicing/static/slice-call.js +56 -88
  233. package/slicing/static/static-slicer.js +115 -79
  234. package/slicing/static/visiting-queue.d.ts +4 -6
  235. package/slicing/static/visiting-queue.js +9 -13
  236. package/util/files.d.ts +2 -0
  237. package/util/files.js +3 -1
  238. package/util/mermaid/mermaid.js +6 -2
  239. package/util/proc.js +2 -1
  240. package/util/r-base-packages.d.ts +2 -0
  241. package/util/r-base-packages.js +23 -13
  242. package/util/text/playground-link.d.ts +12 -3
  243. package/util/text/playground-link.js +18 -27
  244. package/util/version.js +4 -10
@@ -7,53 +7,24 @@ const doc_files_1 = require("./doc-util/doc-files");
7
7
  const doc_query_1 = require("./doc-util/doc-query");
8
8
  const schema_1 = require("../util/schema");
9
9
  const ansi_1 = require("../util/text/ansi");
10
- const call_context_query_executor_1 = require("../queries/catalog/call-context-query/call-context-query-executor");
11
- const compound_query_1 = require("../queries/virtual-query/compound-query");
12
10
  const example_query_code_1 = require("./data/query/example-query-code");
13
11
  const doc_structure_1 = require("./doc-util/doc-structure");
14
12
  const doc_code_1 = require("./doc-util/doc-code");
15
- const dataflow_query_executor_1 = require("../queries/catalog/dataflow-query/dataflow-query-executor");
16
- const id_map_query_executor_1 = require("../queries/catalog/id-map-query/id-map-query-executor");
17
- const normalized_ast_query_executor_1 = require("../queries/catalog/normalized-ast-query/normalized-ast-query-executor");
18
- const cluster_query_executor_1 = require("../queries/catalog/cluster-query/cluster-query-executor");
19
- const static_slice_query_executor_1 = require("../queries/catalog/static-slice-query/static-slice-query-executor");
20
- const dependencies_query_executor_1 = require("../queries/catalog/dependencies-query/dependencies-query-executor");
21
13
  const doc_cli_option_1 = require("./doc-util/doc-cli-option");
22
14
  const doc_issue_1 = require("./doc-util/doc-issue");
23
- const location_map_query_executor_1 = require("../queries/catalog/location-map-query/location-map-query-executor");
24
15
  const identify_link_to_last_call_relation_1 = require("../queries/catalog/call-context-query/identify-link-to-last-call-relation");
25
- const config_query_executor_1 = require("../queries/catalog/config-query/config-query-executor");
26
- const search_query_executor_1 = require("../queries/catalog/search-query/search-query-executor");
27
16
  const flowr_search_builder_1 = require("../search/flowr-search-builder");
28
17
  const vertex_1 = require("../dataflow/graph/vertex");
29
- const control_flow_query_executor_1 = require("../queries/catalog/control-flow-query/control-flow-query-executor");
30
18
  const doc_cfg_1 = require("./doc-util/doc-cfg");
31
19
  const doc_repl_1 = require("./doc-util/doc-repl");
32
- const inspect_higher_order_query_executor_1 = require("../queries/catalog/inspect-higher-order-query/inspect-higher-order-query-executor");
33
20
  const doc_escape_1 = require("./doc-util/doc-escape");
34
21
  const config_1 = require("../config");
35
22
  const doc_maker_1 = require("./wiki-mk/doc-maker");
36
- const files_query_executor_1 = require("../queries/catalog/files-query/files-query-executor");
37
- const call_graph_query_executor_1 = require("../queries/catalog/call-graph-query/call-graph-query-executor");
38
- const inspect_recursion_query_executor_1 = require("../queries/catalog/inspect-recursion-query/inspect-recursion-query-executor");
39
- const inspect_fn_props_query_executor_1 = require("../queries/catalog/inspect-fn-props-query/inspect-fn-props-query-executor");
40
- const does_call_query_executor_1 = require("../queries/catalog/does-call-query/does-call-query-executor");
41
- const inspect_exception_query_executor_1 = require("../queries/catalog/inspect-exceptions-query/inspect-exception-query-executor");
42
23
  const slice_direction_1 = require("../util/slice-direction");
43
- const provenance_query_executor_1 = require("../queries/catalog/provenance-query/provenance-query-executor");
44
- const input_sources_query_executor_1 = require("../queries/catalog/input-sources-query/input-sources-query-executor");
45
- const absint_query_executor_1 = require("../queries/catalog/absint-query/absint-query-executor");
46
- const dice_query_executor_1 = require("../queries/catalog/dice-query/dice-query-executor");
47
- const dataflow_lens_query_executor_1 = require("../queries/catalog/dataflow-lens-query/dataflow-lens-query-executor");
48
- const signature_query_executor_1 = require("../queries/catalog/signature-query/signature-query-executor");
49
24
  const doc_sigdb_1 = require("./doc-util/doc-sigdb");
50
- const guess_dep_versions_query_executor_1 = require("../queries/catalog/guess-dep-versions-query/guess-dep-versions-query-executor");
51
- const function_info_query_executor_1 = require("../queries/catalog/function-info-query/function-info-query-executor");
52
25
  (0, doc_query_1.registerQueryDocumentation)('call-context', {
53
26
  type: 'active',
54
27
  shortDescription: 'Finds all calls in a set of files that matches specified criteria.',
55
- functionName: call_context_query_executor_1.executeCallContextQueries.name,
56
- functionFile: '../queries/catalog/call-context-query/call-context-query-executor.ts',
57
28
  buildExplanation: async (shell, ctx) => {
58
29
  return `
59
30
  Call context queries can be used to identify calls to specific functions that match criteria of your interest.
@@ -86,7 +57,7 @@ ${await (0, doc_query_1.showQuery)(shell, example_query_code_1.exampleQueryCode,
86
57
  { type: 'call-context', callName: '^points$', kind: 'visualize', subkind: 'plot', linkTo: { type: 'link-to-last-call', callName: '^plot$' } }
87
58
  ], { showCode: false, ctx })}
88
59
 
89
- As you can see, all kinds and subkinds with the same name are grouped together.
60
+ All kinds and subkinds with the same name are grouped together.
90
61
  Yet, re-stating common arguments and kinds may be cumbersome (although you can already use clever regex patterns).
91
62
  See the ${(0, doc_query_1.linkToQueryOfName)('compound')} for a way to structure your queries more compactly if you think it gets too verbose.
92
63
 
@@ -108,8 +79,6 @@ my_test_function()
108
79
  (0, doc_query_1.registerQueryDocumentation)('dataflow', {
109
80
  type: 'active',
110
81
  shortDescription: 'Returns the dataflow graph of the given code.',
111
- functionName: dataflow_query_executor_1.executeDataflowQuery.name,
112
- functionFile: '../queries/catalog/dataflow-query/dataflow-query-executor.ts',
113
82
  buildExplanation: async (shell, ctx) => {
114
83
  const exampleCode = 'x + 1';
115
84
  return `
@@ -124,8 +93,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'dataflow' }], {
124
93
  (0, doc_query_1.registerQueryDocumentation)('call-graph', {
125
94
  type: 'active',
126
95
  shortDescription: 'Returns the call graph of the given code.',
127
- functionName: call_graph_query_executor_1.executeCallGraphQuery.name,
128
- functionFile: '../queries/catalog/call-graph-query/call-graph-query-executor.ts',
129
96
  buildExplanation: async (shell, ctx) => {
130
97
  const exampleCode = 'x + 1';
131
98
  return `
@@ -139,8 +106,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'call-graph' }],
139
106
  (0, doc_query_1.registerQueryDocumentation)('does-call', {
140
107
  type: 'active',
141
108
  shortDescription: 'Checks whether a function calls another function matching given constraints.',
142
- functionName: does_call_query_executor_1.executeDoesCallQuery.name,
143
- functionFile: '../queries/catalog/does-call-query/does-call-query-executor.ts',
144
109
  buildExplanation: async (shell, ctx) => {
145
110
  const exampleCode = 'f <- function(x) { eval(x) };\nf("1 + 1")';
146
111
  return `
@@ -156,8 +121,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'does-call', que
156
121
  (0, doc_query_1.registerQueryDocumentation)('files', {
157
122
  type: 'active',
158
123
  shortDescription: 'Returns the files matching the given criteria.',
159
- functionName: files_query_executor_1.executeFileQuery.name,
160
- functionFile: '../queries/catalog/files-query/files-query-executor.ts',
161
124
  buildExplanation: async (shell, ctx) => {
162
125
  return `
163
126
  This query returns the files that match the given criteria.
@@ -168,8 +131,6 @@ ${await (0, doc_query_1.showQuery)(shell, '', [{ type: 'files' }], { showCode: t
168
131
  (0, doc_query_1.registerQueryDocumentation)('project', {
169
132
  type: 'active',
170
133
  shortDescription: 'Returns information about the analyzed project',
171
- functionName: dataflow_query_executor_1.executeDataflowQuery.name,
172
- functionFile: '../queries/catalog/project-query/project-query-executor.ts',
173
134
  buildExplanation: async (shell, ctx) => {
174
135
  const exampleCode = 'x + 1';
175
136
  return `
@@ -183,8 +144,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'project' }], {
183
144
  (0, doc_query_1.registerQueryDocumentation)('normalized-ast', {
184
145
  type: 'active',
185
146
  shortDescription: 'Returns the normalized AST of the given code.',
186
- functionName: normalized_ast_query_executor_1.executeNormalizedAstQuery.name,
187
- functionFile: '../queries/catalog/normalized-ast-query/normalized-ast-query-executor.ts',
188
147
  buildExplanation: async (shell, ctx) => {
189
148
  const exampleCode = 'x + 1';
190
149
  return `
@@ -199,8 +158,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'normalized-ast'
199
158
  (0, doc_query_1.registerQueryDocumentation)('dataflow-cluster', {
200
159
  type: 'active',
201
160
  shortDescription: 'Calculates and returns all the clusters present in the dataflow graph.',
202
- functionName: cluster_query_executor_1.executeDataflowClusterQuery.name,
203
- functionFile: '../queries/catalog/cluster-query/cluster-query-executor.ts',
204
161
  buildExplanation: async (shell, ctx) => {
205
162
  const exampleA = 'x <- 1; x';
206
163
  const exampleB = 'x <- 1; y';
@@ -223,8 +180,6 @@ ${await (0, doc_query_1.showQuery)(shell, example_query_code_1.exampleQueryCode,
223
180
  (0, doc_query_1.registerQueryDocumentation)('resolve-value', {
224
181
  type: 'active',
225
182
  shortDescription: 'Provides access to flowR\'s value tracking (which is configurable)',
226
- functionName: search_query_executor_1.executeSearch.name,
227
- functionFile: '../queries/catalog/resolve-value-query/resolve-value-query-executor.ts',
228
183
  buildExplanation: async (shell, ctx) => {
229
184
  const exampleCode = 'x <- 1\ny <-2\nprint(x)\nprint(y)';
230
185
  const criteria = ['3@x', '4@y'];
@@ -240,8 +195,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'resolve-value',
240
195
  (0, doc_query_1.registerQueryDocumentation)('inspect-higher-order', {
241
196
  type: 'active',
242
197
  shortDescription: 'Determine whether functions are higher-order functions',
243
- functionName: inspect_higher_order_query_executor_1.executeHigherOrderQuery.name,
244
- functionFile: '../queries/catalog/inspect-higher-order-query/inspect-higher-order-query-executor.ts',
245
198
  buildExplanation: async (shell, ctx) => {
246
199
  const exampleCode = 'f <- function() function(x) x; f()';
247
200
  return `
@@ -260,8 +213,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'inspect-higher-
260
213
  (0, doc_query_1.registerQueryDocumentation)('inspect-recursion', {
261
214
  type: 'active',
262
215
  shortDescription: 'Determine whether functions are recursive',
263
- functionName: inspect_recursion_query_executor_1.executeRecursionQuery.name,
264
- functionFile: '../queries/catalog/inspect-recursion-query/inspect-recursion-query-executor.ts',
265
216
  buildExplanation: async (shell, ctx) => {
266
217
  const exampleCode = 'fact <- function(n) { if(n <= 1) 1 else n * fact(n - 1) }';
267
218
  return `
@@ -279,8 +230,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'inspect-recursi
279
230
  (0, doc_query_1.registerQueryDocumentation)('inspect-fn-props', {
280
231
  type: 'active',
281
232
  shortDescription: 'Determine what functions and their formals do',
282
- functionName: inspect_fn_props_query_executor_1.executeFnPropsQuery.name,
283
- functionFile: '../queries/catalog/inspect-fn-props-query/inspect-fn-props-query-executor.ts',
284
233
  buildExplanation: async (shell, ctx) => {
285
234
  const exampleCode = 'f <- function(x, xs, FUN, opt) { if(missing(opt)) print(length(xs)); lapply(xs, FUN); x }';
286
235
  return `
@@ -318,8 +267,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'inspect-fn-prop
318
267
  (0, doc_query_1.registerQueryDocumentation)('inspect-exception', {
319
268
  type: 'active',
320
269
  shortDescription: 'Determine whether functions throw exceptions (known to flowR)',
321
- functionName: inspect_exception_query_executor_1.executeExceptionQuery.name,
322
- functionFile: '../queries/catalog/inspect-exceptions-query/inspect-exception-query-executor.ts',
323
270
  buildExplanation: async (shell, ctx) => {
324
271
  const exampleCode = `mayFail <- function(x) {
325
272
  if(x < 0) stop("Negative value!")
@@ -344,8 +291,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'inspect-excepti
344
291
  (0, doc_query_1.registerQueryDocumentation)('origin', {
345
292
  type: 'active',
346
293
  shortDescription: 'Retrieve the origin of a variable, function call, ...',
347
- functionName: search_query_executor_1.executeSearch.name,
348
- functionFile: '../queries/catalog/origin-query/origin-query-executor.ts',
349
294
  buildExplanation: async (shell, ctx) => {
350
295
  const exampleCode = 'x <- 1\nprint(x)';
351
296
  const criterion = '2@x';
@@ -361,8 +306,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'origin', criter
361
306
  (0, doc_query_1.registerQueryDocumentation)('search', {
362
307
  type: 'active',
363
308
  shortDescription: 'Provides access to flowR\'s search API',
364
- functionName: search_query_executor_1.executeSearch.name,
365
- functionFile: '../queries/catalog/search-query/search-query-executor.ts',
366
309
  buildExplanation: async (shell, ctx) => {
367
310
  const exampleCode = 'x + 1';
368
311
  return `
@@ -376,8 +319,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'search', search
376
319
  (0, doc_query_1.registerQueryDocumentation)('happens-before', {
377
320
  type: 'active',
378
321
  shortDescription: 'Check whether one normalized AST node happens before another in the CFG.',
379
- functionName: search_query_executor_1.executeSearch.name,
380
- functionFile: '../queries/catalog/happens-before-query/happens-before-query-executor.ts',
381
322
  buildExplanation: async (shell, ctx) => {
382
323
  const exampleCode = 'x <- 1\ny <- 2';
383
324
  return `
@@ -395,8 +336,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'happens-before'
395
336
  (0, doc_query_1.registerQueryDocumentation)('id-map', {
396
337
  type: 'active',
397
338
  shortDescription: 'Returns the id-map of the normalized AST of the given code.',
398
- functionName: id_map_query_executor_1.executeIdMapQuery.name,
399
- functionFile: '../queries/catalog/id-map-query/id-map-query-executor.ts',
400
339
  buildExplanation: async (shell, ctx) => {
401
340
  const exampleCode = 'x + 1';
402
341
  return `
@@ -410,8 +349,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'id-map' }], { s
410
349
  (0, doc_query_1.registerQueryDocumentation)('config', {
411
350
  type: 'active',
412
351
  shortDescription: 'Returns the current configuration of flowR.',
413
- functionName: config_query_executor_1.executeConfigQuery.name,
414
- functionFile: '../queries/catalog/config-query/config-query-format.ts',
415
352
  buildExplanation: async (shell, ctx) => {
416
353
  return `
417
354
  This query provides access to the current configuration of the flowR instance. See the ${ctx.linkPage('wiki/Interface', 'Interface')} wiki page for more information on what the configuration represents.
@@ -438,8 +375,6 @@ enables quick statistics after each REPL command. Likewise, ${ctx.linkConfig('re
438
375
  (0, doc_query_1.registerQueryDocumentation)('absint', {
439
376
  type: 'active',
440
377
  shortDescription: 'Returns the abstract values inferred for every expression or at specific locations.',
441
- functionName: absint_query_executor_1.executeAbsintQuery.name,
442
- functionFile: '../queries/catalog/absint-query/absint-query-format.ts',
443
378
  buildExplanation: async (shell, ctx) => {
444
379
  const criteria = ['1@df', '1@data.frame'];
445
380
  const inference = 'df-shape';
@@ -457,8 +392,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'absint', infere
457
392
  name: 'Compound Query',
458
393
  type: 'virtual',
459
394
  shortDescription: 'Combines multiple queries of the same type into one, specifying common arguments.',
460
- functionName: compound_query_1.executeCompoundQueries.name,
461
- functionFile: '../queries/virtual-query/compound-query.ts',
462
395
  buildExplanation: async (shell, ctx) => {
463
396
  return `
464
397
  A compound query comes in use, whenever we want to state multiple queries of the same type with a set of common arguments.
@@ -473,7 +406,7 @@ assigned to the kind \`visualize\` and the subkind \`text\` (using the example c
473
406
 
474
407
  ${await (0, doc_query_1.showQuery)(shell, example_query_code_1.exampleQueryCode, [{ type: 'compound', query: 'call-context', commonArguments: { kind: 'visualize', subkind: 'text' }, arguments: [{ callName: '^mean$' }, { callName: '^print$' }] }], { showCode: false, ctx })}
475
408
 
476
- Of course, in this specific scenario, the following query would be equivalent:
409
+ In this specific scenario, the following query would be equivalent:
477
410
 
478
411
  ${await (0, doc_query_1.showQuery)(shell, example_query_code_1.exampleQueryCode, [{ type: 'call-context', callName: '^(mean|print)$', kind: 'visualize', subkind: 'text' }], { showCode: false, collapseResult: true, ctx })}
479
412
 
@@ -492,8 +425,6 @@ Now, the results no longer contain calls to \`plot\` that are not defined locall
492
425
  (0, doc_query_1.registerQueryDocumentation)('static-slice', {
493
426
  type: 'active',
494
427
  shortDescription: 'Slice the dataflow graph reducing the code to just the parts relevant for the given criteria (backward and forward).',
495
- functionName: static_slice_query_executor_1.executeStaticSliceQuery.name,
496
- functionFile: '../queries/catalog/static-slice-query/static-slice-query-executor.ts',
497
428
  buildExplanation: async (shell, ctx) => {
498
429
  const exampleCode = 'x <- 1\ny <- 2\nz <- 3\nx';
499
430
  const criteria = ['3@z', '4@x'];
@@ -540,8 +471,6 @@ This query replaces the old ${ctx.linkPage('wiki/Interface', '`request-slice`',
540
471
  (0, doc_query_1.registerQueryDocumentation)('provenance', {
541
472
  type: 'active',
542
473
  shortDescription: 'Calculate the provenance of a given variable, optionally restricted to its enveloping fdef',
543
- functionName: provenance_query_executor_1.executeProvenanceQuery.name,
544
- functionFile: '../queries/catalog/provenance-query/provenance-query-executor.ts',
545
474
  buildExplanation: async (shell, ctx) => {
546
475
  const exampleCode = 'x <- 1\ny <- 2\nz <- 3\nx';
547
476
  const criterion = '4@x';
@@ -560,8 +489,6 @@ ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'provenance', cr
560
489
  (0, doc_query_1.registerQueryDocumentation)('input-sources', {
561
490
  type: 'active',
562
491
  shortDescription: 'Classify the input sources of function calls',
563
- functionName: input_sources_query_executor_1.executeInputSourcesQuery.name,
564
- functionFile: '../queries/catalog/input-sources-query/input-sources-query-executor.ts',
565
492
  buildExplanation: async (shell, ctx) => {
566
493
  const exampleCode = `
567
494
  f <- function(x) {
@@ -617,8 +544,6 @@ ${(0, doc_code_1.codeBlock)('json', JSON.stringify({ inputSources: {
617
544
  (0, doc_query_1.registerQueryDocumentation)('dependencies', {
618
545
  type: 'active',
619
546
  shortDescription: 'Returns all direct dependencies (in- and outputs) of a given R script',
620
- functionName: dependencies_query_executor_1.executeDependenciesQuery.name,
621
- functionFile: '../queries/catalog/dependencies-query/dependencies-query-executor.ts',
622
547
  buildExplanation: async (shell, ctx) => {
623
548
  const exampleCode = 'library(x)';
624
549
  const longerCode = `
@@ -638,10 +563,10 @@ This query extracts all dependencies from an R script, using a combination of a
638
563
  and more advanced tracking in the ${ctx.linkPage('wiki/Dataflow Graph', 'Dataflow Graph')}.
639
564
  Loaded libraries are resolved against the ${ctx.linkPage('wiki/Signature Database', 'signature database')}.
640
565
 
641
- In other words, if you have a script simply reading: \`${exampleCode}\`, the following query returns the loaded library:
566
+ For a script reading \`${exampleCode}\`, the following query returns the loaded library:
642
567
  ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'dependencies' }], { showCode: false, collapseQuery: true, ctx })}
643
568
 
644
- Of course, this works for more complicated scripts too. The query offers information on the loaded _libraries_, _sourced_ files, data which is _read_ and data which is _written_.
569
+ The query also handles more complicated scripts and offers information on the loaded _libraries_, _sourced_ files, data which is _read_ and data which is _written_.
645
570
  For example, consider the following script:
646
571
  ${(0, doc_code_1.codeBlock)('r', longerCode)}
647
572
  The following query returns the dependencies of the script.
@@ -673,14 +598,12 @@ suggest a \`library\` call for.
673
598
  (0, doc_query_1.registerQueryDocumentation)('linter', {
674
599
  type: 'active',
675
600
  shortDescription: 'Lints a given R script for common issues.',
676
- functionName: dependencies_query_executor_1.executeDependenciesQuery.name,
677
- functionFile: '../queries/catalog/linter-query/linter-query-executor.ts',
678
601
  buildExplanation: async (shell, ctx) => {
679
602
  const exampleCode = 'read.csv("i_do_not_exist.csv")';
680
603
  return `
681
604
  This query lints a given R script for common issues, such as missing files, unused variables, and more.
682
605
 
683
- In other words, if you have a script simply reading: \`${exampleCode}\`, the following query returns all smells detected:
606
+ For a script reading \`${exampleCode}\`, the following query returns all smells detected:
684
607
  ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'linter' }], { showCode: false, collapseQuery: true, ctx })}
685
608
 
686
609
  You can also configure which rules to apply and what settings to use for these rules:
@@ -693,14 +616,12 @@ We welcome any feedback and suggestions for new rules on this (consider opening
693
616
  (0, doc_query_1.registerQueryDocumentation)('control-flow', {
694
617
  type: 'active',
695
618
  shortDescription: 'Provides the control-flow of the program.',
696
- functionName: control_flow_query_executor_1.executeControlFlowQuery.name,
697
- functionFile: '../queries/catalog/control-flow-query/control-flow-query-executor.ts',
698
619
  buildExplanation: async (shell, ctx) => {
699
620
  const exampleCode = 'if(TRUE) 1 else 2';
700
621
  return `
701
622
  This control-flow query provides you access to the control flow graph.
702
623
 
703
- In other words, if you have a script simply reading: \`${exampleCode}\`, the following query returns the CFG:
624
+ For a script reading \`${exampleCode}\`, the following query returns the CFG:
704
625
  ${await (0, doc_query_1.showQuery)(shell, exampleCode, [{ type: 'control-flow' }], { showCode: false, collapseQuery: true, collapseResult: true, ctx })}
705
626
 
706
627
  You can also overwrite the simplification passes to tune the perspective. for example, if you want to have basic blocks:
@@ -732,8 +653,6 @@ ${await (0, doc_cfg_1.printCfgCode)(shell, exampleCode, { showCode: false, prefi
732
653
  (0, doc_query_1.registerQueryDocumentation)('location-map', {
733
654
  type: 'active',
734
655
  shortDescription: 'Returns a simple mapping of ids to their location in the source file',
735
- functionName: location_map_query_executor_1.executeLocationMapQuery.name,
736
- functionFile: '../queries/catalog/location-map-query/location-map-query-executor.ts',
737
656
  buildExplanation: async (shell, ctx) => {
738
657
  const exampleCode = 'x + 1\nx * 2';
739
658
  const criteria = ['1@x', '2@x'];
@@ -761,8 +680,6 @@ All locations are given as a ${ctx.link('SourceRange')} paired with the file id
761
680
  (0, doc_query_1.registerQueryDocumentation)('dice', {
762
681
  type: 'active',
763
682
  shortDescription: 'Reduces the code to the parts that carry information from a given start point to a given end point.',
764
- functionName: dice_query_executor_1.executeDiceQuery.name,
765
- functionFile: '../queries/catalog/dice-query/dice-query-executor.ts',
766
683
  buildExplanation: async (shell, ctx) => {
767
684
  const exampleCode = 'x <- 1\ny <- 2\nz <- x + y\nw <- z * 2\nprint(z)';
768
685
  return `
@@ -793,8 +710,6 @@ ${(0, doc_structure_1.details)('Multiple Criteria per Side', 'Each side accepts
793
710
  (0, doc_query_1.registerQueryDocumentation)('dataflow-lens', {
794
711
  type: 'active',
795
712
  shortDescription: 'Returns a simplified view on the dataflow graph, reduced to definitions, uses, and calls.',
796
- functionName: dataflow_lens_query_executor_1.executeDataflowLensQuery.name,
797
- functionFile: '../queries/catalog/dataflow-lens-query/dataflow-lens-query-executor.ts',
798
713
  buildExplanation: async (shell, ctx) => {
799
714
  const exampleCode = 'f <- function(a) a + 1\nx <- 1\ny <- f(x)\nprint(y)';
800
715
  return `
@@ -822,8 +737,6 @@ Use the ${(0, doc_query_1.linkToQueryOfName)('dataflow')} if you need the comple
822
737
  (0, doc_query_1.registerQueryDocumentation)('signature', {
823
738
  type: 'active',
824
739
  shortDescription: 'Inspects the signature database: packages, function signatures, source and documentation links.',
825
- functionName: signature_query_executor_1.executeSignatureQuery.name,
826
- functionFile: '../queries/catalog/signature-query/signature-query-executor.ts',
827
740
  buildExplanation: async (shell, ctx) => {
828
741
  const exampleCode = 'library(dplyr)\nlead(1:10, n = 1)';
829
742
  return `
@@ -874,8 +787,6 @@ function guessDepVersionsExampleOptions(ctx) {
874
787
  (0, doc_query_1.registerQueryDocumentation)('guess-dep-versions', {
875
788
  type: 'active',
876
789
  shortDescription: 'Guesses the version range each dependency must have, from declared constraints and actual code usage.',
877
- functionName: guess_dep_versions_query_executor_1.executeGuessDepVersionsQuery.name,
878
- functionFile: '../queries/catalog/guess-dep-versions-query/guess-dep-versions-query-executor.ts',
879
790
  buildExplanation: async (shell, ctx) => {
880
791
  const exampleCode = 'library(dplyr)\nmutate(mtcars, across(everything(), round))';
881
792
  return `
@@ -935,8 +846,6 @@ See the ${(0, doc_query_1.linkToQueryOfName)('signature')} to inspect the signat
935
846
  (0, doc_query_1.registerQueryDocumentation)('function-info', {
936
847
  type: 'active',
937
848
  shortDescription: 'Reports where a function name comes from: which packages export it, their signature, and whether flowR itself has a built-in definition for it.',
938
- functionName: function_info_query_executor_1.executeFunctionInfoQuery.name,
939
- functionFile: '../queries/catalog/function-info-query/function-info-query-executor.ts',
940
849
  buildExplanation: async (shell, ctx) => {
941
850
  return `
942
851
  This query answers "where does this function come from?" for a bare name, combining two sources flowR otherwise
@@ -1003,8 +912,7 @@ In general, we separate two types of queries:
1003
912
  1. **Active Queries**: Are exactly what you would expect from a query (e.g., the ${(0, doc_query_1.linkToQueryOfName)('call-context')}). They fetch information from the dataflow graph.
1004
913
  2. **Virtual Queries**: Are used to structure your queries (e.g., the ${(0, doc_query_1.linkToQueryOfName)('compound')}).
1005
914
 
1006
- We separate these from a concept perspective.
1007
- For now, we support the following **active** queries (which we will refer to simply as a \`query\`):
915
+ We support the following **active** queries (which we refer to as a \`query\`):
1008
916
 
1009
917
  ${(0, doc_query_1.tocForQueryType)('active')}
1010
918
 
@@ -1017,7 +925,7 @@ ${(0, doc_query_1.tocForQueryType)('virtual')}
1017
925
 
1018
926
  <summary>Detailed Query Format (Automatically Generated)</summary>
1019
927
 
1020
- Although it is probably better to consult the detailed explanations, if you want to have a look at the schema, here is its description:
928
+ The schema of the query format:
1021
929
 
1022
930
  ${(0, schema_1.describeSchema)((0, query_1.QueriesSchema)(), ansi_1.markdownFormatter)}
1023
931
 
@@ -1025,7 +933,7 @@ ${(0, schema_1.describeSchema)((0, query_1.QueriesSchema)(), ansi_1.markdownForm
1025
933
 
1026
934
  ### Why Queries?
1027
935
 
1028
- First, consider that you have a file like the following (of course, this is just a simple and artificial example):
936
+ First, consider that you have a file like the following (a simple, artificial example):
1029
937
 
1030
938
  \`\`\`r
1031
939
  ${example_query_code_1.exampleQueryCode}
@@ -19,6 +19,7 @@ Want to try it without installing anything? Run code straight away in the ${(0,
19
19
  Otherwise, you can download and build it from source, download the accompanying ${ctx.linkPage('flowr:docker', 'docker image')},
20
20
  or use its ${ctx.linkPage('flowr:vscode', 'Visual Studio Code extension')} and ${ctx.linkPage('flowr:rstudio-addin', 'RStudio Addin')}.
21
21
 
22
+ - [🌐 Using the Playground](#-using-the-playground)
22
23
  - [🗒️ Using the Visual Studio Code Extension](#-using-the-visual-studio-code-extension)
23
24
  - [🗒️ Using the RStudio Addin](#-using-the-rstudio-addin)
24
25
  - [🐳️ Using the Docker Image](#-using-the-docker-image)
@@ -29,6 +30,17 @@ or use its ${ctx.linkPage('flowr:vscode', 'Visual Studio Code extension')} and $
29
30
  If you want to develop for _flowR_, you want to see how to [build from scratch](#-building-from-scratch) and have a
30
31
  look at the [Contributing Guidelines](${doc_files_1.RemoteFlowrFilePathBaseRef}.github/CONTRIBUTING.md).
31
32
 
33
+ ## 🌐 Using the Playground
34
+
35
+ The ${(0, doc_playground_1.linkToPlayground)('Playground', {})} runs _flowR_ in your browser and updates the dependencies, lints, and slice while you type.
36
+ It can also execute the script with [webR](https://docs.r-wasm.org/webr/latest/).
37
+ Press Run (or <kbd>Ctrl</kbd>+<kbd>Enter</kbd>) to evaluate the script in a fresh workspace.
38
+ The first run downloads R (about 30 MB), and packages loaded with \`library()\`, \`require()\`, or \`pkg::\` are installed when needed.
39
+ In the repl, lines starting with \`:\` are _flowR_ commands (see \`:help\`), all other lines are evaluated as R in the same session.
40
+ webR is downloaded from its CDN, and the page checks every file against the pinned webR release, whose npm signature and checksum the build verifies. A file that does not match is refused and R does not run.
41
+ R runs inside the browser with its own in-memory file system and cannot call \`system()\`.
42
+ Shared links contain the script and the _flowR_ commands only, never R input for the repl.
43
+
32
44
  ## 🗒️ Using the Visual Studio Code Extension
33
45
 
34
46
  The easiest way to use _flowR_ is to install the ${ctx.linkPage('flowr:vscode', 'Visual Studio Code extension')}.
@@ -115,6 +127,17 @@ For details on _how_ to contribute, please refer to the [CONTRIBUTING.md](${doc_
115
127
 
116
128
  _flowR_ knows the exported functions of thousands of R packages, resolving \`library(pkg)\`/\`pkg::fn\` calls from a downloaded signature database (\`flowr-sigdb\`); no shards are committed (only the \`sigdb.remote.json\` pointer), everything else is fetched on demand. Search it live at [flowr-analysis.github.io/flowr/wiki/sigdb](${doc_files_1.FlowrSiteBaseRef}/wiki/sigdb/), try _flowR_ itself in the ${(0, doc_playground_1.linkToPlayground)('Playground', {})} without installing anything, or see the ${ctx.linkPage('wiki/Signature Database')} page for how the database works.
117
129
 
130
+ ### 🌐 Working on the Playground
131
+
132
+ The playground lives in \`scripts/playground/\`. Its bundle is not committed, the documentation job builds it for GitHub Pages.
133
+ To build and serve it locally:
134
+
135
+ \`\`\`shell
136
+ npm run preview:playground
137
+ \`\`\`
138
+
139
+ Then open [localhost:8000/playground/](http://localhost:8000/playground/).
140
+
118
141
  ### 📦 Using _flowR_ as a Dependency in Another Project
119
142
 
120
143
  _flowR_ is published as \`@eagleoutice/flowr\`, but you may want an unreleased branch or a local build instead. Plain \`npm install /path/to/flowr\` (or \`npm link\`) looks like it works, but skips resolving _flowR_'s own dependencies, so the bundled WASM parser fails at runtime with an \`ENOENT\` on \`tree-sitter.wasm\`. Package a tarball instead, which installs like any normal package:
@@ -258,7 +258,7 @@ what lets a package function answer the same questions a built-in does.
258
258
 
259
259
  Per version the source also answers declared dependencies (${ctx.link('ResolvedDependency')}), release dates, the plain export view (${ctx.link('LibraryExports')}), the versions it carries (${ctx.link('AvailableVersion')}), and its class relations (${ctx.link('SigClassInfo')}, via ${ctx.linkM(reader_1.SigDatabase, 'classes')}).
260
260
 
261
- A class record states what a declaration does: its direct superclasses, its slots with the types they were declared with, whether it is virtual, and whether it is a \`setClassUnion\` (whose supers are the members it unites). ${ctx.link('SigClassInfo::package')} names the package *defining* a class the record only relates to, which is what tells a class the package owns from one it inherits -- something the flat name list of ${ctx.link('LibraryExports::s4Classes')} has nowhere to hang. The same shape carries Reference classes, S7 and R6, since all four declare a name, a parent and a set of members. On the analysis side ${ctx.link('declaredClasses')} reads these off \`setClass\`/\`setClassUnion\`/\`setIs\`/\`setRefClass\`/\`new_class\`/\`R6Class\` calls and ${ctx.link('toSigClasses')} hands them over in this form.
261
+ A class record states what a declaration does: its direct superclasses, its slots with the types they were declared with, whether it is virtual, and whether it is a \`setClassUnion\` (whose supers are the members it unites). ${ctx.link('SigClassInfo::package')} names the package *defining* a class the record only relates to, which is what tells a class the package owns from one it inherits -- something the flat name list of ${ctx.link('LibraryExports::s4Classes')} has nowhere to hang. The same shape carries Reference classes, S7 and R6, since all four declare a name, a parent and a set of members. On the analysis side ${ctx.link('declaredClassesImpl')} reads these off \`setClass\`/\`setClassUnion\`/\`setIs\`/\`setRefClass\`/\`new_class\`/\`R6Class\` calls and ${ctx.link('toSigClassesImpl')} hands them over in this form.
262
262
 
263
263
  Beyond the flags above, ${ctx.link('DecodedFunction::props')} also carry ${ctx.linkE('FnProp', 'NoDoc')} (a documented package has no help page for this name), ${ctx.linkE('FnProp', 'S3Method')} (a registered S3 method, from the package NAMESPACE or base R's method table), and ${ctx.linkE('FnProp', 'S3Owner')} (an exported constructor for an S3 class this package OWNS: it also registers at least one S3 method for that class). The owned classes of a version are ${ctx.link('LibraryExports::s3Classes')}, and ${ctx.linkM(reader_1.SigDatabase, 'classOwner')} answers, for a class name, which package owns it (backed by a reverse index built once). This lets ${ctx.linkPage('wiki/Query API', 'version guessing')} mark a package used when the analyzed project's own NAMESPACE registers an S3 method for a class it owns, even with no direct call, e.g. tseries's \`S3method("as.irts","zoo")\` marks \`zoo\` used.
264
264
 
@@ -24,7 +24,7 @@ export declare const LintingRules: {
24
24
  readonly description: "Marks deprecated functions and deprecated arguments of still-current functions, offering the replacement as a quick fix where one is known. A call to a bare name whose package the code never attaches is reported as uncertain, as any function of that name would answer to it.";
25
25
  readonly defaultConfig: (ctx: import("../project/context/flowr-analyzer-context").ReadOnlyFlowrAnalyzerContext) => {
26
26
  always: import("..").Identifier[];
27
- conditionally: Record<import("../dataflow/environments/identifier").BrandedIdentifier, import("./rules/deprecated-functions").DeprecatedFunctionInformation>;
27
+ conditionally: Record<import("../dataflow/environments/identifier").BrandedIdentifier, import("../dataflow/environments/deprecation-info").DeprecatedFunctionInformation>;
28
28
  };
29
29
  };
30
30
  };
@@ -52,7 +52,7 @@ export declare const LintingRules: {
52
52
  };
53
53
  };
54
54
  readonly 'seeded-randomness': {
55
- readonly createSearch: (config: import("./rules/seeded-randomness").SeededRandomnessConfig, data: import("..").ReadonlyFlowrAnalysisProvider<import("..").KnownParser>) => import("../search/flowr-search-builder").FlowrSearchBuilder<"all", ["filter", "with", "filter", "with"], import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, Promise<import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>>>;
55
+ readonly createSearch: (config: import("./rules/seeded-randomness").SeededRandomnessConfig) => import("../search/flowr-search-builder").FlowrSearchBuilder<"all", ["filter", "with", "filter"], import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, Promise<import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, [] | import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>>>;
56
56
  readonly processSearchResult: (elements: import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>, config: import("./rules/seeded-randomness").SeededRandomnessConfig, data: import("..").ReadonlyFlowrAnalysisProvider<import("..").KnownParser>) => Promise<{
57
57
  results: {
58
58
  involvedId: import("..").NodeId;
@@ -64,10 +64,13 @@ export declare const LintingRules: {
64
64
  }>;
65
65
  readonly info: {
66
66
  readonly defaultConfig: (ctx: import("../project/context/flowr-analyzer-context").ReadOnlyFlowrAnalyzerContext) => {
67
- randomnessProducers: {
68
- type: "function" | "assignment";
67
+ randomnessProducers: ({
68
+ readonly type: "function";
69
+ readonly name: string;
70
+ } | {
71
+ type: "assignment";
69
72
  name: string;
70
- }[];
73
+ })[];
71
74
  randomnessConsumers: string[];
72
75
  };
73
76
  readonly tags: readonly [import("./linter-tags").LintingRuleTag.Robustness, import("./linter-tags").LintingRuleTag.Reproducibility];
@@ -129,7 +132,7 @@ export declare const LintingRules: {
129
132
  };
130
133
  };
131
134
  readonly 'naming-convention': {
132
- readonly createSearch: (_config: import("./rules/naming-convention").NamingConventionConfig) => import("../search/flowr-search-builder").FlowrSearchBuilder<"all", ["filter"], import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, Promise<import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, [] | import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>>>;
135
+ readonly createSearch: () => import("../search/flowr-search-builder").FlowrSearchBuilder<"all", ["filter"], import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, Promise<import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, [] | import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>>>;
133
136
  readonly processSearchResult: (elements: import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>, config: import("./rules/naming-convention").NamingConventionConfig, data: import("..").ReadonlyFlowrAnalysisProvider<import("..").KnownParser>) => Promise<{
134
137
  results: import("./rules/naming-convention").NamingConventionResult[];
135
138
  '.meta': {
@@ -258,7 +261,7 @@ export declare const LintingRules: {
258
261
  };
259
262
  };
260
263
  readonly 'stop-call': {
261
- readonly createSearch: () => import("../search/flowr-search-builder").FlowrSearchBuilder<"get", ["filter"], import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, Promise<import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, [] | import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>>>;
264
+ readonly createSearch: () => import("../search/flowr-search-builder").FlowrSearchBuilder<"all", ["filter"], import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, Promise<import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, [] | import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>>>;
262
265
  readonly processSearchResult: (elements: import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>, _config: import("../util/objects").MergeableRecord, data: import("..").ReadonlyFlowrAnalysisProvider<import("..").KnownParser>) => Promise<{
263
266
  results: import("ts-essentials").Writable<import("./rules/stop-with-call-arg").StopWithCallResult>[];
264
267
  '.meta': import("./rules/stop-with-call-arg").StopWithCallMetadata;
@@ -277,8 +280,14 @@ export declare const LintingRules: {
277
280
  };
278
281
  readonly 'roxygen-arguments': {
279
282
  readonly createSearch: () => import("../search/flowr-search-builder").FlowrSearchBuilder<"all", ["filter", "with"], import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, Promise<import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>>>;
280
- readonly processSearchResult: (elements: import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>, _config: import("../util/objects").MergeableRecord) => {
281
- results: import("ts-essentials").Writable<import("./rules/roxygen-arguments").RoxygenArgsResult>[];
283
+ readonly processSearchResult: (elements: import("../search/flowr-search").FlowrSearchElements<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../search/flowr-search").FlowrSearchElement<import("../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>[]>) => {
284
+ results: {
285
+ certainty: import("./linter-format").LintingResultCertainty.Uncertain;
286
+ involvedId: import("..").NodeId;
287
+ loc: [startLine: number, startColumn: number, endLine: number, endColumn: number, f?: string | undefined];
288
+ underDocumented: string[];
289
+ overDocumented: string[];
290
+ }[];
282
291
  '.meta': {};
283
292
  };
284
293
  readonly prettyPrint: {