@eagleoutice/flowr 2.12.3 → 2.13.1

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 (321) hide show
  1. package/README.md +42 -95
  2. package/abstract-interpretation/data-frame/dataframe-domain.d.ts +3 -3
  3. package/abstract-interpretation/data-frame/dataframe-domain.js +14 -6
  4. package/abstract-interpretation/data-frame/semantics.js +12 -16
  5. package/abstract-interpretation/domains/abstract-domain.d.ts +46 -44
  6. package/abstract-interpretation/domains/abstract-domain.js +146 -6
  7. package/abstract-interpretation/domains/bounded-set-domain.d.ts +16 -25
  8. package/abstract-interpretation/domains/bounded-set-domain.js +22 -69
  9. package/abstract-interpretation/domains/interval-domain.d.ts +27 -36
  10. package/abstract-interpretation/domains/interval-domain.js +111 -146
  11. package/abstract-interpretation/domains/lattice.d.ts +3 -3
  12. package/abstract-interpretation/domains/multi-value-state-domain.js +3 -3
  13. package/abstract-interpretation/domains/partial-product-domain.d.ts +12 -19
  14. package/abstract-interpretation/domains/partial-product-domain.js +21 -54
  15. package/abstract-interpretation/domains/positive-interval-domain.d.ts +8 -12
  16. package/abstract-interpretation/domains/positive-interval-domain.js +21 -50
  17. package/abstract-interpretation/domains/product-domain.d.ts +1 -1
  18. package/abstract-interpretation/domains/product-domain.js +4 -4
  19. package/abstract-interpretation/domains/set-range-domain.d.ts +60 -56
  20. package/abstract-interpretation/domains/set-range-domain.js +141 -200
  21. package/abstract-interpretation/domains/set-upper-bound-domain.d.ts +17 -23
  22. package/abstract-interpretation/domains/set-upper-bound-domain.js +59 -103
  23. package/abstract-interpretation/domains/singleton-domain.d.ts +15 -18
  24. package/abstract-interpretation/domains/singleton-domain.js +33 -72
  25. package/abstract-interpretation/domains/state-abstract-domain.d.ts +12 -16
  26. package/abstract-interpretation/domains/state-abstract-domain.js +36 -126
  27. package/abstract-interpretation/domains/state-domain-like.d.ts +2 -2
  28. package/abstract-interpretation/domains/value-abstract-domain.d.ts +120 -0
  29. package/abstract-interpretation/domains/{satisfiable-domain.js → value-abstract-domain.js} +14 -2
  30. package/benchmark/slicer.d.ts +2 -2
  31. package/benchmark/slicer.js +6 -5
  32. package/cli/common/options.d.ts +20 -0
  33. package/cli/common/options.js +4 -0
  34. package/cli/common/scripts-info.d.ts +20 -0
  35. package/cli/flowr-main-options.d.ts +4 -0
  36. package/cli/flowr-main-options.js +5 -0
  37. package/cli/flowr.d.ts +5 -0
  38. package/cli/flowr.js +15 -7
  39. package/cli/repl/commands/repl-commands.d.ts +8 -0
  40. package/cli/repl/commands/repl-commands.js +16 -3
  41. package/cli/repl/commands/repl-query.js +50 -20
  42. package/cli/repl/commands/repl-signature.js +2 -2
  43. package/cli/repl/core.d.ts +14 -5
  44. package/cli/repl/core.js +32 -17
  45. package/cli/repl/parser/slice-query-parser.d.ts +69 -8
  46. package/cli/repl/parser/slice-query-parser.js +82 -13
  47. package/cli/repl/path-input.d.ts +6 -0
  48. package/cli/repl/path-input.js +41 -0
  49. package/cli/repl/print-version.js +3 -5
  50. package/cli/slicer-app.d.ts +4 -0
  51. package/cli/slicer-app.js +4 -2
  52. package/config.d.ts +56 -6
  53. package/config.js +134 -12
  54. package/control-flow/control-flow-graph.d.ts +3 -2
  55. package/control-flow/control-flow-graph.js +34 -14
  56. package/control-flow/semantic-cfg-guided-visitor.d.ts +3 -0
  57. package/control-flow/semantic-cfg-guided-visitor.js +3 -0
  58. package/core/steps/all/static-slicing/10-reconstruct.d.ts +6 -0
  59. package/core/steps/all/static-slicing/10-reconstruct.js +3 -1
  60. package/data/r-base-packages.generated.d.ts +1 -1
  61. package/data/r-base-packages.generated.js +3 -3
  62. package/data/sigdb/sigdb.remote.json +53 -53
  63. package/dataflow/environments/built-in-proc-name.d.ts +2 -0
  64. package/dataflow/environments/built-in-proc-name.js +2 -0
  65. package/dataflow/environments/built-in.d.ts +2 -0
  66. package/dataflow/environments/built-in.js +2 -0
  67. package/dataflow/environments/default-builtin-config.d.ts +3 -5
  68. package/dataflow/environments/default-builtin-config.js +2 -2
  69. package/dataflow/environments/environment.d.ts +9 -0
  70. package/dataflow/environments/environment.js +28 -7
  71. package/dataflow/environments/identifier.d.ts +1 -2
  72. package/dataflow/environments/identifier.js +1 -5
  73. package/dataflow/extractor.js +1 -2
  74. package/dataflow/graph/dataflowgraph-builder.js +42 -3
  75. package/dataflow/graph/df-helper.d.ts +15 -0
  76. package/dataflow/graph/df-helper.js +20 -0
  77. package/dataflow/internal/process/functions/call/built-in/built-in-attach.js +4 -4
  78. package/dataflow/internal/process/functions/call/built-in/built-in-envir-utils.d.ts +7 -0
  79. package/dataflow/internal/process/functions/call/built-in/built-in-envir-utils.js +13 -0
  80. package/dataflow/internal/process/functions/call/built-in/built-in-library.d.ts +4 -0
  81. package/dataflow/internal/process/functions/call/built-in/built-in-library.js +57 -11
  82. package/dataflow/internal/process/functions/call/built-in/built-in-load.d.ts +12 -0
  83. package/dataflow/internal/process/functions/call/built-in/built-in-load.js +233 -0
  84. package/dataflow/internal/process/functions/call/built-in/built-in-source.js +2 -1
  85. package/dataflow/internal/process/functions/call/built-in/built-in-with.js +5 -3
  86. package/documentation/data/faq/faqs.js +12 -1
  87. package/documentation/doc-readme.js +1 -1
  88. package/documentation/doc-util/doc-files.d.ts +2 -2
  89. package/documentation/doc-util/doc-files.js +4 -7
  90. package/documentation/doc-util/doc-query.d.ts +12 -9
  91. package/documentation/doc-util/doc-query.js +63 -28
  92. package/documentation/wiki-absint.js +1 -4
  93. package/documentation/wiki-analyzer.js +8 -3
  94. package/documentation/wiki-cfg.js +3 -2
  95. package/documentation/wiki-dataflow-graph.js +14 -4
  96. package/documentation/wiki-interface.js +30 -16
  97. package/documentation/wiki-mk/doc-maker.js +1 -1
  98. package/documentation/wiki-query.js +190 -30
  99. package/documentation/wiki-signature-database.d.ts +1 -1
  100. package/documentation/wiki-signature-database.js +53 -27
  101. package/linter/linter-output.d.ts +24 -0
  102. package/linter/linter-output.js +117 -0
  103. package/linter/linter-rules.d.ts +2 -4
  104. package/linter/rules/dataframe-access-validation.js +4 -4
  105. package/linter/rules/deprecated-functions.d.ts +2 -4
  106. package/linter/rules/deprecated-functions.js +58 -3
  107. package/linter/rules/undefined-symbol.js +18 -10
  108. package/linter/rules/unused-definition.js +24 -0
  109. package/package.json +5 -2
  110. package/project/context/flowr-analyzer-context.d.ts +61 -1
  111. package/project/context/flowr-analyzer-context.js +124 -3
  112. package/project/context/flowr-analyzer-dependencies-context.d.ts +32 -7
  113. package/project/context/flowr-analyzer-dependencies-context.js +33 -3
  114. package/project/context/flowr-analyzer-files-context.d.ts +40 -0
  115. package/project/context/flowr-analyzer-files-context.js +171 -14
  116. package/project/context/flowr-analyzer-loading-order-context.d.ts +6 -0
  117. package/project/context/flowr-analyzer-loading-order-context.js +20 -0
  118. package/project/context/flowr-analyzer-meta-context.d.ts +92 -10
  119. package/project/context/flowr-analyzer-meta-context.js +64 -23
  120. package/project/context/flowr-file.d.ts +7 -0
  121. package/project/context/flowr-file.js +7 -0
  122. package/project/context/project-kind.d.ts +22 -0
  123. package/project/context/project-kind.js +27 -0
  124. package/project/dependency-version-space.d.ts +168 -0
  125. package/project/dependency-version-space.js +570 -0
  126. package/project/flowr-analyzer-builder.js +1 -1
  127. package/project/flowr-analyzer.d.ts +7 -0
  128. package/project/flowr-analyzer.js +9 -0
  129. package/project/plugins/file-plugins/files/flowr-description-file.d.ts +4 -0
  130. package/project/plugins/file-plugins/files/flowr-description-file.js +7 -0
  131. package/project/plugins/file-plugins/files/flowr-namespace-file.js +5 -1
  132. package/project/plugins/file-plugins/files/flowr-rda-file.d.ts +739 -0
  133. package/project/plugins/file-plugins/files/flowr-rda-file.js +2407 -0
  134. package/project/plugins/file-plugins/files/flowr-rproject-file.d.ts +31 -0
  135. package/project/plugins/file-plugins/files/flowr-rproject-file.js +66 -0
  136. package/project/plugins/file-plugins/files/r-fun-tab.d.ts +828 -0
  137. package/project/plugins/file-plugins/files/r-fun-tab.js +1039 -0
  138. package/project/plugins/file-plugins/flowr-analyzer-description-file-plugin.d.ts +1 -1
  139. package/project/plugins/file-plugins/flowr-analyzer-description-file-plugin.js +1 -1
  140. package/project/plugins/file-plugins/flowr-analyzer-file-plugin.js +1 -1
  141. package/project/plugins/file-plugins/flowr-analyzer-inst-file-plugin.d.ts +1 -1
  142. package/project/plugins/file-plugins/flowr-analyzer-inst-file-plugin.js +1 -1
  143. package/project/plugins/file-plugins/flowr-analyzer-license-file-plugin.d.ts +1 -1
  144. package/project/plugins/file-plugins/flowr-analyzer-license-file-plugin.js +1 -1
  145. package/project/plugins/file-plugins/flowr-analyzer-namespace-files-plugin.d.ts +1 -1
  146. package/project/plugins/file-plugins/flowr-analyzer-namespace-files-plugin.js +1 -1
  147. package/project/plugins/file-plugins/flowr-analyzer-news-file-plugin.d.ts +1 -1
  148. package/project/plugins/file-plugins/flowr-analyzer-news-file-plugin.js +1 -1
  149. package/project/plugins/file-plugins/flowr-analyzer-rda-file-plugin.d.ts +26 -0
  150. package/project/plugins/file-plugins/flowr-analyzer-rda-file-plugin.js +38 -0
  151. package/project/plugins/file-plugins/flowr-analyzer-rprofile-file-plugin.d.ts +17 -0
  152. package/project/plugins/file-plugins/flowr-analyzer-rprofile-file-plugin.js +30 -0
  153. package/project/plugins/file-plugins/flowr-analyzer-rproject-file-plugin.d.ts +22 -0
  154. package/project/plugins/file-plugins/flowr-analyzer-rproject-file-plugin.js +36 -0
  155. package/project/plugins/file-plugins/flowr-analyzer-test-file-plugin.d.ts +1 -1
  156. package/project/plugins/file-plugins/flowr-analyzer-test-file-plugin.js +1 -1
  157. package/project/plugins/file-plugins/flowr-analyzer-vignette-file-plugin.d.ts +1 -1
  158. package/project/plugins/file-plugins/flowr-analyzer-vignette-file-plugin.js +1 -1
  159. package/project/plugins/file-plugins/flowr-analyzer-virtualenv-file-plugin.d.ts +3 -4
  160. package/project/plugins/file-plugins/flowr-analyzer-virtualenv-file-plugin.js +5 -6
  161. package/project/plugins/flowr-analyzer-plugin.js +5 -0
  162. package/project/plugins/loading-order-plugins/flowr-analyzer-loading-order-description-file-plugin.d.ts +1 -1
  163. package/project/plugins/loading-order-plugins/flowr-analyzer-loading-order-description-file-plugin.js +1 -1
  164. package/project/plugins/loading-order-plugins/flowr-analyzer-loading-order-implicit-sources-plugin.d.ts +14 -0
  165. package/project/plugins/loading-order-plugins/flowr-analyzer-loading-order-implicit-sources-plugin.js +53 -0
  166. package/project/plugins/loading-order-plugins/flowr-analyzer-loading-order-plugin.js +1 -1
  167. package/project/plugins/loading-order-plugins/flowr-analyzer-loading-order-rprofile-plugin.d.ts +15 -0
  168. package/project/plugins/loading-order-plugins/flowr-analyzer-loading-order-rprofile-plugin.js +33 -0
  169. package/project/plugins/package-version-plugins/flowr-analyzer-meta-description-file-plugin.d.ts +1 -1
  170. package/project/plugins/package-version-plugins/flowr-analyzer-meta-description-file-plugin.js +18 -13
  171. package/project/plugins/package-version-plugins/flowr-analyzer-meta-rproject-file-plugin.d.ts +13 -0
  172. package/project/plugins/package-version-plugins/flowr-analyzer-meta-rproject-file-plugin.js +32 -0
  173. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-description-file-plugin.d.ts +1 -1
  174. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-description-file-plugin.js +1 -1
  175. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-lockfile-plugin.d.ts +8 -1
  176. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-lockfile-plugin.js +70 -7
  177. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-namespace-file-plugin.d.ts +1 -1
  178. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-namespace-file-plugin.js +1 -1
  179. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-plugin.js +1 -1
  180. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-session-info-plugin.d.ts +18 -0
  181. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-session-info-plugin.js +62 -0
  182. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-sigdb-plugin.d.ts +4 -1
  183. package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-sigdb-plugin.js +5 -13
  184. package/project/plugins/package-version-plugins/package.d.ts +4 -1
  185. package/project/plugins/package-version-plugins/package.js +8 -5
  186. package/project/plugins/plugin-registry.d.ts +11 -3
  187. package/project/plugins/plugin-registry.js +24 -5
  188. package/project/plugins/project-discovery/flowr-analyzer-ignore-file-project-discovery-plugin.d.ts +51 -0
  189. package/project/plugins/project-discovery/flowr-analyzer-ignore-file-project-discovery-plugin.js +101 -0
  190. package/project/plugins/project-discovery/flowr-analyzer-project-discovery-plugin.js +10 -5
  191. package/project/sigdb/build.js +12 -2
  192. package/project/sigdb/decode.d.ts +7 -0
  193. package/project/sigdb/decode.js +35 -4
  194. package/project/sigdb/decompress.d.ts +2 -0
  195. package/project/sigdb/decompress.js +5 -0
  196. package/project/sigdb/manifest.d.ts +5 -0
  197. package/project/sigdb/manifest.js +37 -6
  198. package/project/sigdb/reader.d.ts +82 -2
  199. package/project/sigdb/reader.js +226 -14
  200. package/project/sigdb/schema.d.ts +31 -5
  201. package/project/sigdb/schema.js +7 -3
  202. package/project/sigdb/{version.d.ts → sigdb-version.d.ts} +21 -1
  203. package/project/sigdb/sigdb-version.js +119 -0
  204. package/queries/catalog/absint-query/absint-query-format.d.ts +2 -0
  205. package/queries/catalog/absint-query/absint-query-format.js +2 -0
  206. package/queries/catalog/call-context-query/call-context-query-executor.js +30 -3
  207. package/queries/catalog/call-context-query/call-context-query-format.d.ts +1 -0
  208. package/queries/catalog/call-context-query/call-context-query-format.js +1 -0
  209. package/queries/catalog/call-graph-query/call-graph-query-executor.js +3 -1
  210. package/queries/catalog/call-graph-query/call-graph-query-format.d.ts +6 -0
  211. package/queries/catalog/call-graph-query/call-graph-query-format.js +2 -0
  212. package/queries/catalog/call-graph-query/expand-library-internals.d.ts +19 -0
  213. package/queries/catalog/call-graph-query/expand-library-internals.js +59 -0
  214. package/queries/catalog/cluster-query/cluster-query-format.d.ts +1 -0
  215. package/queries/catalog/cluster-query/cluster-query-format.js +1 -0
  216. package/queries/catalog/config-query/config-query-executor.js +17 -5
  217. package/queries/catalog/config-query/config-query-format.d.ts +19 -3
  218. package/queries/catalog/config-query/config-query-format.js +258 -98
  219. package/queries/catalog/control-flow-query/control-flow-query-format.d.ts +1 -0
  220. package/queries/catalog/control-flow-query/control-flow-query-format.js +1 -0
  221. package/queries/catalog/dataflow-lens-query/dataflow-lens-query-format.d.ts +1 -0
  222. package/queries/catalog/dataflow-lens-query/dataflow-lens-query-format.js +1 -0
  223. package/queries/catalog/dataflow-query/dataflow-query-format.d.ts +1 -0
  224. package/queries/catalog/dataflow-query/dataflow-query-format.js +1 -0
  225. package/queries/catalog/dependencies-query/dependencies-query-executor.js +2 -7
  226. package/queries/catalog/dependencies-query/dependencies-query-format.d.ts +13 -1
  227. package/queries/catalog/dependencies-query/dependencies-query-format.js +117 -17
  228. package/queries/catalog/dice-query/dice-query-executor.js +6 -9
  229. package/queries/catalog/dice-query/dice-query-format.d.ts +4 -5
  230. package/queries/catalog/dice-query/dice-query-format.js +10 -6
  231. package/queries/catalog/does-call-query/does-call-query-executor.js +15 -2
  232. package/queries/catalog/does-call-query/does-call-query-format.d.ts +8 -0
  233. package/queries/catalog/does-call-query/does-call-query-format.js +4 -1
  234. package/queries/catalog/files-query/files-query-format.d.ts +2 -0
  235. package/queries/catalog/files-query/files-query-format.js +2 -0
  236. package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-executor.d.ts +6 -0
  237. package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-executor.js +293 -0
  238. package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-format.d.ts +121 -0
  239. package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-format.js +345 -0
  240. package/queries/catalog/happens-before-query/happens-before-query-format.d.ts +1 -0
  241. package/queries/catalog/happens-before-query/happens-before-query-format.js +1 -0
  242. package/queries/catalog/id-map-query/id-map-query-format.d.ts +1 -0
  243. package/queries/catalog/id-map-query/id-map-query-format.js +1 -0
  244. package/queries/catalog/input-sources-query/input-sources-query-format.d.ts +2 -0
  245. package/queries/catalog/input-sources-query/input-sources-query-format.js +2 -0
  246. package/queries/catalog/inspect-exceptions-query/inspect-exception-query-format.d.ts +2 -0
  247. package/queries/catalog/inspect-exceptions-query/inspect-exception-query-format.js +2 -0
  248. package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-format.d.ts +2 -0
  249. package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-format.js +2 -0
  250. package/queries/catalog/inspect-recursion-query/inspect-recursion-query-format.d.ts +2 -0
  251. package/queries/catalog/inspect-recursion-query/inspect-recursion-query-format.js +2 -0
  252. package/queries/catalog/linter-query/linter-query-executor.js +11 -2
  253. package/queries/catalog/linter-query/linter-query-format.d.ts +9 -4
  254. package/queries/catalog/linter-query/linter-query-format.js +44 -21
  255. package/queries/catalog/location-map-query/location-map-query-format.d.ts +2 -0
  256. package/queries/catalog/location-map-query/location-map-query-format.js +2 -0
  257. package/queries/catalog/normalized-ast-query/normalized-ast-query-format.d.ts +1 -0
  258. package/queries/catalog/normalized-ast-query/normalized-ast-query-format.js +1 -0
  259. package/queries/catalog/origin-query/origin-query-format.d.ts +2 -0
  260. package/queries/catalog/origin-query/origin-query-format.js +2 -0
  261. package/queries/catalog/project-query/project-query-executor.d.ts +0 -15
  262. package/queries/catalog/project-query/project-query-executor.js +19 -62
  263. package/queries/catalog/project-query/project-query-format.d.ts +7 -18
  264. package/queries/catalog/project-query/project-query-format.js +3 -18
  265. package/queries/catalog/provenance-query/provenance-query-format.d.ts +2 -0
  266. package/queries/catalog/provenance-query/provenance-query-format.js +2 -0
  267. package/queries/catalog/resolve-value-query/resolve-value-query-format.d.ts +2 -0
  268. package/queries/catalog/resolve-value-query/resolve-value-query-format.js +2 -0
  269. package/queries/catalog/search-query/search-query-format.d.ts +1 -0
  270. package/queries/catalog/search-query/search-query-format.js +1 -0
  271. package/queries/catalog/signature-query/signature-query-executor.d.ts +5 -0
  272. package/queries/catalog/signature-query/signature-query-executor.js +267 -57
  273. package/queries/catalog/signature-query/signature-query-format.d.ts +37 -6
  274. package/queries/catalog/signature-query/signature-query-format.js +41 -5
  275. package/queries/catalog/signature-query/signature-query-render.js +48 -6
  276. package/queries/catalog/slice-query-options.d.ts +49 -0
  277. package/queries/catalog/slice-query-options.js +50 -0
  278. package/queries/catalog/static-slice-query/static-slice-query-executor.js +4 -12
  279. package/queries/catalog/static-slice-query/static-slice-query-format.d.ts +4 -15
  280. package/queries/catalog/static-slice-query/static-slice-query-format.js +9 -10
  281. package/queries/query-print.js +3 -1
  282. package/queries/query.d.ts +62 -2
  283. package/queries/query.js +9 -2
  284. package/r-bridge/data/data.d.ts +16 -0
  285. package/r-bridge/data/data.js +20 -0
  286. package/r-bridge/lang-4.x/ast/model/model.d.ts +1 -0
  287. package/r-bridge/lang-4.x/ast/model/processing/decorate.js +2 -1
  288. package/r-bridge/lang-4.x/ast/parser/main/internal/normalize-access.js +2 -1
  289. package/r-bridge/lang-4.x/tree-sitter/tree-sitter-normalize.js +19 -16
  290. package/reconstruct/reconstruct.d.ts +18 -1
  291. package/reconstruct/reconstruct.js +42 -19
  292. package/slicing/criterion/parse.d.ts +4 -0
  293. package/slicing/criterion/parse.js +4 -0
  294. package/slicing/static/slice-call.js +17 -9
  295. package/slicing/static/static-slicer.d.ts +1 -1
  296. package/slicing/static/static-slicer.js +5 -4
  297. package/util/files.d.ts +19 -1
  298. package/util/files.js +45 -3
  299. package/util/glob.d.ts +19 -0
  300. package/util/glob.js +67 -0
  301. package/util/log.d.ts +12 -0
  302. package/util/log.js +17 -1
  303. package/util/logic.d.ts +6 -0
  304. package/util/logic.js +31 -1
  305. package/util/mermaid/dfg.js +17 -12
  306. package/util/mermaid/mermaid.js +2 -2
  307. package/util/objects.d.ts +5 -0
  308. package/util/objects.js +8 -0
  309. package/util/r-version.d.ts +9 -1
  310. package/util/r-version.js +27 -2
  311. package/util/schema.d.ts +18 -0
  312. package/util/schema.js +102 -4
  313. package/util/text/ansi.d.ts +4 -0
  314. package/util/text/ansi.js +27 -3
  315. package/util/text/strings.d.ts +9 -0
  316. package/util/text/strings.js +29 -0
  317. package/util/version.js +79 -6
  318. package/abstract-interpretation/domains/satisfiable-domain.d.ts +0 -29
  319. package/project/plugins/project-discovery/flowr-analyzer-gitignore-project-discovery-plugin.d.ts +0 -22
  320. package/project/plugins/project-discovery/flowr-analyzer-gitignore-project-discovery-plugin.js +0 -52
  321. package/project/sigdb/version.js +0 -55
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.PosIntervalDomain = exports.PosIntervalTop = void 0;
4
+ const abstract_domain_1 = require("./abstract-domain");
4
5
  const interval_domain_1 = require("./interval-domain");
5
6
  const lattice_1 = require("./lattice");
6
7
  /** The Top element of the positive interval domain as interval [0, +∞] */
@@ -23,77 +24,47 @@ class PosIntervalDomain extends interval_domain_1.IntervalDomain {
23
24
  return new PosIntervalDomain(value);
24
25
  }
25
26
  static top() {
26
- return new PosIntervalDomain(exports.PosIntervalTop);
27
+ return new this(exports.PosIntervalTop);
27
28
  }
28
29
  static bottom() {
29
- return new PosIntervalDomain(lattice_1.Bottom);
30
- }
31
- static abstract(concrete) {
32
- if (concrete === lattice_1.Top) {
33
- return PosIntervalDomain.top();
34
- }
35
- else if (concrete.size === 0 || concrete.values().some(value => isNaN(value) || value < 0)) {
36
- return PosIntervalDomain.bottom();
37
- }
38
- return new PosIntervalDomain([Math.min(...concrete), Math.max(...concrete)]);
30
+ return new this(lattice_1.Bottom);
39
31
  }
40
32
  top() {
41
- return PosIntervalDomain.top();
33
+ return this.create(exports.PosIntervalTop);
42
34
  }
43
- bottom() {
44
- return PosIntervalDomain.bottom();
45
- }
46
- widen(other) {
47
- if (this.value === lattice_1.Bottom) {
48
- return this.create(other.value);
49
- }
50
- else if (other.value === lattice_1.Bottom) {
51
- return this.create(this.value);
52
- }
53
- else {
54
- return this.create([
55
- this.value[0] <= other.value[0] ? this.value[0] : 0,
56
- this.value[1] >= other.value[1] ? this.value[1] : +Infinity
57
- ]);
58
- }
35
+ widenValue(other) {
36
+ return this.create([
37
+ this.lower <= other.lower ? this.lower : 0,
38
+ this.upper >= other.upper ? this.upper : +Infinity
39
+ ]);
59
40
  }
60
- narrow(other) {
61
- if (this.value === lattice_1.Bottom || other.value === lattice_1.Bottom) {
62
- return this.bottom();
63
- }
64
- else if (Math.max(this.value[0], other.value[0]) > Math.min(this.value[1], other.value[1])) {
41
+ narrowValue(other) {
42
+ if (Math.max(this.lower, other.lower) > Math.min(this.upper, other.upper)) {
65
43
  return this.bottom();
66
44
  }
67
45
  return this.create([
68
- this.value[0] === 0 ? other.value[0] : this.value[0],
69
- this.value[1] === +Infinity ? other.value[1] : this.value[1]
46
+ this.lower === 0 ? other.lower : this.lower,
47
+ this.upper === +Infinity ? other.upper : this.upper
70
48
  ]);
71
49
  }
72
- abstract(concrete) {
73
- return PosIntervalDomain.abstract(concrete);
74
- }
75
50
  subtract(other) {
76
- const otherValue = other instanceof PosIntervalDomain ? other.value : other;
77
- if (this.value === lattice_1.Bottom || otherValue === lattice_1.Bottom) {
78
- return this.bottom();
79
- }
80
- else {
81
- return this.create([Math.max(this.value[0] - otherValue[0], 0), Math.max(this.value[1] - otherValue[1], 0)]);
51
+ const otherValue = other instanceof abstract_domain_1.AbstractDomain ? other.value : other;
52
+ if (this.isValue() && otherValue !== lattice_1.Bottom) {
53
+ return this.create([Math.max(this.lower - otherValue[0], 0), Math.max(this.upper - otherValue[1], 0)]);
82
54
  }
55
+ return this.bottom();
83
56
  }
84
57
  /**
85
58
  * Extends the lower bound of the current abstract value down to 0.
86
59
  */
87
60
  widenDown() {
88
- if (this.value === lattice_1.Bottom) {
89
- return this.bottom();
90
- }
91
- else {
92
- return this.create([0, this.value[1]]);
61
+ if (this.isValue()) {
62
+ return this.create([0, this.upper]);
93
63
  }
64
+ return this.bottom();
94
65
  }
95
66
  isTop() {
96
- return this.value !== lattice_1.Bottom && this.value[0] === 0 && this.value[1] === +Infinity;
67
+ return this.value !== lattice_1.Bottom && this.lower === 0 && this.upper === +Infinity;
97
68
  }
98
69
  }
99
70
  exports.PosIntervalDomain = PosIntervalDomain;
@@ -7,7 +7,7 @@ import { type AbstractProduct, PartialProductDomain } from './partial-product-do
7
7
  */
8
8
  export declare abstract class ProductDomain<Product extends Required<AbstractProduct>> extends PartialProductDomain<Product> {
9
9
  constructor(value: Product);
10
- abstract create(value: Product): this;
10
+ abstract create(value: Product, reduce?: boolean): this;
11
11
  top(): this;
12
12
  isTop(): boolean;
13
13
  isTop(): this is this;
@@ -14,11 +14,11 @@ class ProductDomain extends partial_product_domain_1.PartialProductDomain {
14
14
  super(value, value);
15
15
  }
16
16
  top() {
17
- const result = this.create(this.domain);
18
- for (const key in result.value) {
19
- result.value[key] = result.value[key]?.top();
17
+ const result = {};
18
+ for (const key in this.domain) {
19
+ result[key] = this.domain[key]?.top();
20
20
  }
21
- return result;
21
+ return this.create(result);
22
22
  }
23
23
  isTop() {
24
24
  return record_1.Record.values(this.value).every(value => value.isTop());
@@ -1,104 +1,108 @@
1
1
  import { Ternary } from '../../util/logic';
2
2
  import { AbstractDomain } from './abstract-domain';
3
3
  import { Bottom, Top } from './lattice';
4
- import type { SatisfiableDomain } from './satisfiable-domain';
5
- import { SetComparator } from './satisfiable-domain';
6
- /** The Top element of the set range domain with an empty set as minimum set and {@link Top} as range set */
4
+ import { SetComparator, type SetDomain } from './value-abstract-domain';
5
+ /** The Top element of the set range domain with an empty set as must set and {@link Top} as may set */
7
6
  export declare const SetRangeTop: {
8
- readonly min: Set<never>;
9
- readonly range: typeof Top;
7
+ readonly must: Set<never>;
8
+ readonly may: typeof Top;
10
9
  };
11
- /** The type of the actual values of the set range domain as tuple with a minimum set and range set of additional possible values (i.e. `[{"id","name"}, ∅]`, or `[{"id"}, {"score"}]`) */
12
- type SetRangeValue<T> = {
13
- readonly min: ReadonlySet<T>;
14
- readonly range: ReadonlySet<T> | typeof Top;
10
+ /** The type of the actual values of the set range domain as tuple with a set of values that must be present and a set of values that may be present (i.e. `[{"id","name"}, ∅]`, or `[{"id"}, {"score"}]`) */
11
+ export type SetRangeValue<T> = {
12
+ readonly must: ReadonlySet<T>;
13
+ readonly may: ReadonlySet<T> | typeof Top;
15
14
  };
16
- /** The type of the Top element of the set range domain as tuple with the empty set as minimum set and {@link Top} as range set (i.e. `[∅, Top]`) */
15
+ /** The type of the Top element of the set range domain as tuple with the empty set as must set and {@link Top} as may set (i.e. `[∅, Top]`) */
17
16
  type SetRangeTop = typeof SetRangeTop;
18
17
  /** The type of the Bottom element of the set range domain as {@link Bottom} */
19
18
  type SetRangeBottom = typeof Bottom;
20
19
  /** The type of the abstract values of the set range domain that are Top, Bottom, or actual values */
21
20
  type SetRangeLift<T> = SetRangeValue<T> | SetRangeTop | SetRangeBottom;
22
- /** The type of the actual values of the set range domain with a finite range (the range cannot be Top) */
21
+ /** The type of the actual values of the set range domain with a finite may set (the may set cannot be Top) */
23
22
  type SetRangeFinite<T> = {
24
- readonly min: ReadonlySet<T>;
25
- readonly range: ReadonlySet<T>;
23
+ readonly must: ReadonlySet<T>;
24
+ readonly may: ReadonlySet<T>;
26
25
  };
27
- /** The type of the actual values of the set range domain as array tuple with a minimum array and range array for better readability (e.g. `[["id","name"], []]`, or `[["id"], ["score"]]`) */
26
+ type SetRangeMustSet<T, Value extends SetRangeLift<T>> = Value extends SetRangeValue<T> ? ReadonlySet<T> : ReadonlySet<T> | typeof Bottom;
27
+ type SetRangeMaySet<T, Value extends SetRangeLift<T>> = Value extends SetRangeFinite<T> ? ReadonlySet<T> : Value extends SetRangeValue<T> ? ReadonlySet<T> | typeof Top : ReadonlySet<T> | typeof Top | typeof Bottom;
28
+ /** The type of the actual values of the set range domain as array tuple with a must array and may array for better readability (e.g. `[["id","name"], []]`, or `[["id"], ["score"]]`) */
28
29
  export type ArrayRangeValue<T> = {
29
- readonly min: T[];
30
- readonly range: T[] | typeof Top;
30
+ readonly must: T[];
31
+ readonly may: T[] | typeof Top;
31
32
  };
32
- /** The type for the maximum number of elements in the minimum set and maximum set of the set range domain before over-approximation */
33
+ /** The type for the maximum number of elements in the must set and may set of the set range domain before over-approximation */
33
34
  export type SetRangeLimit = {
34
- readonly min: number;
35
- readonly range: number;
35
+ readonly must: number;
36
+ readonly may: number;
36
37
  };
37
38
  /**
38
- * The set range abstract domain as range of possible value sets with a minimum set of values and a range of possible additional values
39
+ * The set range abstract domain as range of possible value sets with a set of values that must be present and a set of values that may be present
39
40
  * (similar to an interval-like structure with a lower bound and a difference to the upper bound).
40
- * The Bottom element is defined as {@link Bottom} symbol and the Top element is defined as the range `[∅, Top]` where the minimum set is the empty set and the range is {@link Top}.
41
+ * The Bottom element is defined as {@link Bottom} symbol and the Top element is defined as the range `[∅, Top]` where the must set is the empty set and the may set is {@link Top}.
41
42
  * @template T - Type of the values in the sets in the abstract domain
42
43
  * @template Value - Type of the constraint in the abstract domain (Top, Bottom, or an actual value)
43
44
  */
44
- export declare class SetRangeDomain<T, Value extends SetRangeLift<T> = SetRangeLift<T>> extends AbstractDomain<ReadonlySet<T>, SetRangeValue<T>, SetRangeTop, SetRangeBottom, Value> implements SatisfiableDomain<ReadonlySet<T>> {
45
+ export declare class SetRangeDomain<T, Value extends SetRangeLift<T> = SetRangeLift<T>> extends AbstractDomain<SetRangeValue<T>, SetRangeTop, SetRangeBottom, Value> implements SetDomain<T> {
45
46
  readonly limit: SetRangeLimit;
46
- private readonly setType;
47
+ protected readonly setType: typeof Set<T>;
47
48
  /**
48
- * @param limit - A limit for the maximum number of elements to store in the minimum set and maximum set before over-approximation
49
+ * @param limit - A limit for the maximum number of elements to store in the must set and may set before over-approximation
49
50
  * @param newSet - An optional set constructor for the domain elements if the type `T` is not storable in a HashSet
50
51
  */
51
52
  constructor(value: Value | ArrayRangeValue<T>, limit?: SetRangeLimit | number, setType?: typeof Set<T>);
52
53
  create(value: SetRangeLift<T> | ArrayRangeValue<T>): this;
53
54
  /**
54
- * The minimum set (lower bound) of the set range representing all values that must exist (subset of {@link upper}).
55
+ * The set of values that must be present in the set.
55
56
  */
56
- lower(): Value extends SetRangeValue<T> ? ReadonlySet<T> : ReadonlySet<T> | typeof Bottom;
57
+ get must(): SetRangeMustSet<T, Value>;
57
58
  /**
58
- * The maximum set (upper bound) of the set range representing all values that can possibly exist (union of {@link lower} and range).
59
+ * The set of values that may be present in the set (can be {@link Top}).
59
60
  */
60
- upper(): Value extends SetRangeFinite<T> ? ReadonlySet<T> : Value extends SetRangeValue<T> ? ReadonlySet<T> | typeof Top : ReadonlySet<T> | typeof Top | typeof Bottom;
61
+ get may(): SetRangeMaySet<T, Value>;
62
+ /**
63
+ * The lower bound of the set range representing all values that must be present (equals the must set).
64
+ */
65
+ lower(this: SetRangeDomain<T, SetRangeValue<T>>): ReadonlySet<T>;
66
+ lower(this: SetRangeDomain<T, SetRangeLift<T>>): ReadonlySet<T> | typeof Bottom;
67
+ /**
68
+ * The upper bound of the set range representing all values that can possibly be present (union of must set and may set).
69
+ */
70
+ upper(this: SetRangeDomain<T, SetRangeFinite<T>>): ReadonlySet<T>;
71
+ upper(this: SetRangeDomain<T, SetRangeValue<T>>): ReadonlySet<T> | typeof Top;
72
+ upper(this: SetRangeDomain<T, SetRangeLift<T>>): ReadonlySet<T> | typeof Top | typeof Bottom;
73
+ from(...values: ReadonlySet<T>[] | T[][]): this;
61
74
  static top<T>(limit?: SetRangeLimit | number, setType?: typeof Set<T>): SetRangeDomain<T, SetRangeTop>;
62
75
  static bottom<T>(limit?: SetRangeLimit | number, setType?: typeof Set<T>): SetRangeDomain<T, SetRangeBottom>;
63
- static abstract<T>(concrete: ReadonlySet<ReadonlySet<T>> | typeof Top, limit?: SetRangeLimit | number, setType?: typeof Set<T>): SetRangeDomain<T>;
76
+ static from<T>(values: Set<T> | T[] | Set<T>[] | T[][], limit?: SetRangeLimit | number, setType?: typeof Set<T>): SetRangeDomain<T>;
64
77
  top(): this & SetRangeDomain<T, SetRangeTop>;
65
78
  bottom(): this & SetRangeDomain<T, SetRangeBottom>;
66
- equals(other: this): boolean;
67
- leq(other: this): boolean;
68
- join(other: SetRangeLift<T> | ArrayRangeValue<T>): this;
69
- join(other: this): this;
70
- meet(other: SetRangeLift<T> | ArrayRangeValue<T>): this;
71
- meet(other: this): this;
72
- /**
73
- * Creates the union of this abstract value and another abstract value by creating the union of the minimum and maximum set, respectively.
74
- */
79
+ protected equalsValue(this: SetRangeDomain<T, SetRangeValue<T>>, other: SetRangeDomain<T, SetRangeValue<T>>): boolean;
80
+ protected leqValue(this: SetRangeDomain<T, SetRangeValue<T>>, other: SetRangeDomain<T, SetRangeValue<T>>): boolean;
81
+ protected joinValue(this: this & SetRangeDomain<T, SetRangeValue<T>>, other: SetRangeDomain<T, SetRangeValue<T>>): this;
82
+ protected meetValue(this: this & SetRangeDomain<T, SetRangeValue<T>>, other: SetRangeDomain<T, SetRangeValue<T>>): this;
75
83
  union(other: this | SetRangeLift<T> | ArrayRangeValue<T>): this;
76
- /**
77
- * Creates the intersection of this abstract value and another abstract value by creating the intersection of the minimum and maximum set, respectively.
78
- */
79
84
  intersect(other: this | SetRangeLift<T> | ArrayRangeValue<T>): this;
80
- /**
81
- * Subtracts another abstract value from the current abstract value by removing all elements of the other abstract value from the current abstract value.
82
- */
83
85
  subtract(other: this | SetRangeLift<T> | ArrayRangeValue<T>): this;
84
- widen(other: this): this;
85
- narrow(other: this): this;
86
- concretize(limit: number): ReadonlySet<ReadonlySet<T>> | typeof Top;
87
- abstract(concrete: ReadonlySet<ReadonlySet<T>> | typeof Top): this;
86
+ protected widenValue(this: this & SetRangeDomain<T, SetRangeValue<T>>, other: SetRangeDomain<T, SetRangeValue<T>>): this;
87
+ protected narrowValue(this: this & SetRangeDomain<T, SetRangeValue<T>>, other: SetRangeDomain<T, SetRangeValue<T>>): this;
88
88
  satisfies(set: ReadonlySet<T> | T[], comparator?: SetComparator): Ternary;
89
89
  /**
90
- * Extends the minimum set of the current abstract value down to the empty set.
90
+ * Extends the must set of the current abstract value down to the empty set.
91
91
  */
92
92
  widenDown(): this;
93
93
  /**
94
- * Extends the maximum set of the current abstract value up to {@link Top}.
94
+ * Extends the may set of the current abstract value up to {@link Top}.
95
95
  */
96
96
  widenUp(): this;
97
- toJSON(): unknown;
98
- toString(): string;
99
- isTop(): this is SetRangeDomain<T, SetRangeTop>;
100
- isBottom(): this is SetRangeDomain<T, SetRangeBottom>;
101
- isValue(): this is SetRangeDomain<T, SetRangeValue<T>>;
102
- isFinite(): this is SetRangeDomain<T, SetRangeFinite<T>>;
97
+ protected jsonify(this: SetRangeDomain<T, SetRangeValue<T>>): unknown;
98
+ protected stringify(this: SetRangeDomain<T, SetRangeValue<T>>): string;
99
+ isTop(): this is this & SetRangeDomain<T, SetRangeTop>;
100
+ isBottom(): this is this & SetRangeDomain<T, SetRangeBottom>;
101
+ isValue(): this is this & SetRangeDomain<T, SetRangeValue<T>>;
102
+ isFinite(): this is this & SetRangeDomain<T, SetRangeFinite<T>>;
103
+ isInfinite(): this is this & SetRangeDomain<T, {
104
+ readonly must: ReadonlySet<T>;
105
+ readonly may: typeof Top;
106
+ }>;
103
107
  }
104
108
  export {};