@eagleoutice/flowr 2.14.1 → 2.14.3
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.
- package/README.md +142 -87
- package/abstract-interpretation/absint-visitor.d.ts +132 -25
- package/abstract-interpretation/absint-visitor.js +459 -99
- package/abstract-interpretation/data-frame/mappers/access-mapper.d.ts +1 -1
- package/abstract-interpretation/data-frame/mappers/access-mapper.js +4 -4
- package/abstract-interpretation/data-frame/mappers/arguments.d.ts +1 -1
- package/abstract-interpretation/data-frame/mappers/arguments.js +1 -1
- package/abstract-interpretation/data-frame/mappers/function-mapper.js +107 -254
- package/abstract-interpretation/data-frame/mappers/replacement-mapper.js +5 -5
- package/abstract-interpretation/data-frame/resolve-args.d.ts +1 -1
- package/abstract-interpretation/data-frame/resolve-args.js +6 -4
- package/abstract-interpretation/data-frame/shape-inference.d.ts +4 -9
- package/abstract-interpretation/domains/bounded-set-domain.d.ts +1 -0
- package/abstract-interpretation/domains/bounded-set-domain.js +1 -0
- package/abstract-interpretation/domains/partial-product-domain.js +1 -1
- package/abstract-interpretation/domains/set-range-domain.d.ts +3 -2
- package/abstract-interpretation/domains/set-range-domain.js +3 -2
- package/abstract-interpretation/domains/set-upper-bound-domain.d.ts +3 -2
- package/abstract-interpretation/domains/set-upper-bound-domain.js +3 -2
- package/benchmark/calibration.d.ts +11 -6
- package/benchmark/calibration.js +19 -8
- package/benchmark/slicer.d.ts +7 -1
- package/benchmark/slicer.js +38 -34
- package/benchmark/stats/count-comments.d.ts +16 -0
- package/benchmark/stats/count-comments.js +30 -0
- package/benchmark/stats/print.js +2 -0
- package/benchmark/stats/size-of.d.ts +7 -3
- package/benchmark/stats/size-of.js +7 -3
- package/benchmark/stats/stats.d.ts +7 -0
- package/benchmark/summarizer/first-phase/process.js +2 -19
- package/benchmark/summarizer/second-phase/graph.js +13 -3
- package/benchmark/summarizer/second-phase/process.js +2 -0
- package/cli/repl/commands/repl-dataflow.js +70 -27
- package/cli/repl/core.d.ts +1 -1
- package/cli/repl/core.js +1 -1
- package/cli/repl/parser/slice-query-parser.js +2 -1
- package/cli/repl/server/connection.d.ts +4 -0
- package/cli/repl/server/connection.js +19 -16
- package/cli/repl/server/messages/message-analysis.d.ts +1 -1
- package/config.d.ts +21 -8
- package/config.js +12 -5
- package/control-flow/basic-cfg-guided-visitor.d.ts +7 -2
- package/control-flow/basic-cfg-guided-visitor.js +37 -24
- package/control-flow/cfg-dead-code.js +44 -33
- package/control-flow/cfg-properties.js +2 -2
- package/control-flow/cfg-simplification.js +6 -5
- package/control-flow/cfg-to-basic-blocks.js +11 -13
- package/control-flow/control-flow-graph.d.ts +179 -189
- package/control-flow/control-flow-graph.js +400 -263
- package/control-flow/dfg-cfg-guided-visitor.d.ts +21 -3
- package/control-flow/dfg-cfg-guided-visitor.js +17 -13
- package/control-flow/diff-cfg.js +6 -14
- package/control-flow/happens-before.js +5 -4
- package/control-flow/semantic-cfg-guided-visitor.d.ts +44 -101
- package/control-flow/semantic-cfg-guided-visitor.js +6 -3
- package/control-flow/simple-visitor.js +14 -15
- package/control-flow/syntax-cfg-guided-visitor.d.ts +2 -1
- package/control-flow/useless-loop.js +18 -14
- package/core/steps/all/core/20-dataflow.d.ts +1 -3
- package/core/steps/pipeline/default-pipelines.d.ts +141 -157
- package/dataflow/cluster.js +7 -0
- package/dataflow/environments/apply-kill.d.ts +6 -0
- package/dataflow/environments/apply-kill.js +63 -31
- package/dataflow/environments/built-in-props.d.ts +5 -1
- package/dataflow/environments/built-in-props.js +4 -0
- package/dataflow/environments/built-in.d.ts +6 -3
- package/dataflow/environments/built-in.js +8 -5
- package/dataflow/environments/clone.d.ts +3 -3
- package/dataflow/environments/clone.js +5 -5
- package/dataflow/environments/default-builtin-config.d.ts +114 -3
- package/dataflow/environments/default-builtin-config.js +137 -35
- package/dataflow/environments/environment.d.ts +5 -5
- package/dataflow/environments/environment.js +5 -5
- package/dataflow/environments/identifier.d.ts +11 -1
- package/dataflow/environments/identifier.js +4 -1
- package/dataflow/environments/resolve-by-name.d.ts +7 -0
- package/dataflow/environments/resolve-by-name.js +12 -0
- package/dataflow/environments/resolve-helper.d.ts +3 -1
- package/dataflow/environments/resolve-helper.js +2 -0
- package/dataflow/eval/resolve/alias-tracking.d.ts +3 -3
- package/dataflow/eval/resolve/alias-tracking.js +3 -3
- package/dataflow/eval/resolve/match-arguments.js +7 -5
- package/dataflow/eval/resolve/node-value.d.ts +3 -1
- package/dataflow/eval/resolve/node-value.js +12 -0
- package/dataflow/eval/resolve/resolve-argument.js +5 -4
- package/dataflow/eval/resolve/resolve-operators.js +9 -6
- package/dataflow/eval/resolve/resolve-strings.js +2 -2
- package/dataflow/eval/resolve/resolve-working-directory.js +4 -3
- package/dataflow/eval/resolve/resolve.js +3 -2
- package/dataflow/eval/values/general.js +8 -5
- package/dataflow/extractor.d.ts +1 -4
- package/dataflow/extractor.js +11 -10
- package/dataflow/fn/exceptions-of-function.d.ts +3 -1
- package/dataflow/fn/strict-function.js +7 -5
- package/dataflow/graph/call-graph.js +2 -2
- package/dataflow/graph/df-helper.d.ts +8 -1
- package/dataflow/graph/diff-dataflow-graph.d.ts +1 -1
- package/dataflow/graph/diff-dataflow-graph.js +19 -2
- package/dataflow/graph/edge.d.ts +38 -2
- package/dataflow/graph/edge.js +32 -2
- package/dataflow/graph/graph.d.ts +4 -3
- package/dataflow/graph/graph.js +6 -2
- package/dataflow/graph/match-args.d.ts +69 -0
- package/dataflow/graph/match-args.js +167 -0
- package/dataflow/info.d.ts +15 -6
- package/dataflow/info.js +0 -17
- package/dataflow/internal/control-flow.d.ts +114 -0
- package/dataflow/internal/control-flow.js +224 -0
- package/dataflow/internal/linker.d.ts +6 -31
- package/dataflow/internal/linker.js +24 -81
- package/dataflow/internal/process/functions/call/argument/unpack-argument.d.ts +1 -1
- package/dataflow/internal/process/functions/call/argument/unpack-argument.js +3 -3
- package/dataflow/internal/process/functions/call/built-in/built-in-access.d.ts +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-access.js +9 -6
- package/dataflow/internal/process/functions/call/built-in/built-in-apply.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-apply.js +6 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-assignment.d.ts +1 -10
- package/dataflow/internal/process/functions/call/built-in/built-in-assignment.js +18 -37
- package/dataflow/internal/process/functions/call/built-in/built-in-attach.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-attach.js +3 -3
- package/dataflow/internal/process/functions/call/built-in/built-in-class-generator.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-class-generator.js +11 -7
- package/dataflow/internal/process/functions/call/built-in/built-in-envir-utils.js +6 -8
- package/dataflow/internal/process/functions/call/built-in/built-in-eval.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-eval.js +18 -14
- package/dataflow/internal/process/functions/call/built-in/built-in-expression-list.js +18 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-for-loop.js +12 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-function-definition.d.ts +2 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-function-definition.js +38 -30
- package/dataflow/internal/process/functions/call/built-in/built-in-get.js +3 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-if-then-else.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-if-then-else.js +36 -8
- package/dataflow/internal/process/functions/call/built-in/built-in-library.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-library.js +20 -17
- package/dataflow/internal/process/functions/call/built-in/built-in-list.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-list.js +6 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-load.js +4 -3
- package/dataflow/internal/process/functions/call/built-in/built-in-local.js +9 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-namespace-access.d.ts +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-namespace-access.js +5 -5
- package/dataflow/internal/process/functions/call/built-in/built-in-new-env.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-new-env.js +5 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-pipe.js +7 -5
- package/dataflow/internal/process/functions/call/built-in/built-in-purrr-formula.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-purrr-formula.js +15 -13
- package/dataflow/internal/process/functions/call/built-in/built-in-quote.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-quote.js +11 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-recall.js +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-register-hook.js +4 -3
- package/dataflow/internal/process/functions/call/built-in/built-in-repeat-loop.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-repeat-loop.js +26 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-replacement.d.ts +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-replacement.js +17 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-rm.d.ts +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-rm.js +71 -33
- package/dataflow/internal/process/functions/call/built-in/built-in-s-seven-new-generic.js +6 -15
- package/dataflow/internal/process/functions/call/built-in/built-in-s-three-dispatch.js +13 -14
- package/dataflow/internal/process/functions/call/built-in/built-in-source.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-source.js +14 -11
- package/dataflow/internal/process/functions/call/built-in/built-in-special-bin-op.js +15 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-stack-env.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-stack-env.js +12 -8
- package/dataflow/internal/process/functions/call/built-in/built-in-stop-if-not.js +6 -5
- package/dataflow/internal/process/functions/call/built-in/built-in-string-template.d.ts +1 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-string-template.js +5 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-try-catch.d.ts +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-try-catch.js +50 -10
- package/dataflow/internal/process/functions/call/built-in/built-in-while-loop.d.ts +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-while-loop.js +20 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-with.js +6 -2
- package/dataflow/internal/process/functions/call/common.js +5 -6
- package/dataflow/internal/process/functions/call/deferred.js +2 -2
- package/dataflow/internal/process/functions/call/known-call-handling.d.ts +12 -2
- package/dataflow/internal/process/functions/call/known-call-handling.js +41 -15
- package/dataflow/internal/process/functions/call/named-call-handling.js +2 -0
- package/dataflow/internal/process/functions/call/nse.d.ts +1 -1
- package/dataflow/internal/process/functions/call/nse.js +6 -1
- package/dataflow/internal/process/functions/call/quoted.js +2 -2
- package/dataflow/internal/process/functions/call/unnamed-call-handling.js +19 -6
- package/dataflow/internal/process/functions/process-argument.d.ts +1 -1
- package/dataflow/internal/process/functions/process-argument.js +12 -4
- package/dataflow/internal/process/functions/process-parameter.js +13 -0
- package/dataflow/internal/process/process-named-call.d.ts +2 -2
- package/dataflow/internal/process/process-named-call.js +9 -7
- package/documentation/data/server/doc-data-server-messages.js +4 -4
- package/documentation/doc-readme.js +33 -0
- package/documentation/doc-util/doc-cfg.d.ts +8 -7
- package/documentation/doc-util/doc-cfg.js +10 -10
- package/documentation/doc-util/doc-playground.d.ts +12 -0
- package/documentation/doc-util/doc-playground.js +21 -0
- package/documentation/doc-util/doc-query.d.ts +4 -1
- package/documentation/doc-util/doc-query.js +4 -2
- package/documentation/wiki-absint.d.ts +3 -4
- package/documentation/wiki-absint.js +17 -5
- package/documentation/wiki-analyzer.js +2 -2
- package/documentation/wiki-cfg.js +101 -106
- package/documentation/wiki-dataflow-graph.js +84 -53
- package/documentation/wiki-interface.js +1 -0
- package/documentation/wiki-linter.js +15 -1
- package/documentation/wiki-linting-and-testing.js +1 -16
- package/documentation/wiki-mk/doc-maker.js +6 -4
- package/documentation/wiki-query.js +14 -4
- package/documentation/wiki-signature-database.js +28 -2
- package/linter/linter-fix.d.ts +16 -0
- package/linter/linter-fix.js +104 -0
- package/linter/linter-format.d.ts +18 -1
- package/linter/linter-format.js +31 -1
- package/linter/linter-output.js +46 -10
- package/linter/linter-rules.d.ts +40 -9
- package/linter/linter-rules.js +2 -0
- package/linter/rules/absolute-path.js +4 -2
- package/linter/rules/dataframe-access-validation.js +6 -7
- package/linter/rules/deprecated-functions.d.ts +107 -10
- package/linter/rules/deprecated-functions.js +311 -23
- package/linter/rules/file-path-validity.js +5 -4
- package/linter/rules/function-finder-util.d.ts +6 -0
- package/linter/rules/function-finder-util.js +21 -13
- package/linter/rules/naming-convention.js +1 -1
- package/linter/rules/network-functions.d.ts +2 -2
- package/linter/rules/stop-with-call-arg.js +2 -2
- package/linter/rules/unclosed-connection.js +2 -2
- package/linter/rules/undefined-symbol-util.js +6 -4
- package/linter/rules/undefined-symbol.js +2 -2
- package/linter/rules/unused-definition.js +8 -4
- package/linter/rules/unused-import.d.ts +60 -0
- package/linter/rules/unused-import.js +179 -0
- package/package.json +2 -2
- package/project/attached-packages.js +2 -1
- package/project/cache/flowr-analyzer-cache.d.ts +2 -5
- package/project/cache/flowr-analyzer-cache.js +4 -7
- package/project/cache/flowr-analyzer-controlflow-cache.d.ts +9 -8
- package/project/cache/flowr-analyzer-controlflow-cache.js +17 -34
- package/project/cache/flowr-cache.d.ts +9 -0
- package/project/cache/flowr-cache.js +19 -0
- package/project/context/flowr-analyzer-context.d.ts +7 -3
- package/project/context/flowr-analyzer-context.js +15 -9
- package/project/context/flowr-analyzer-dependencies-context.d.ts +24 -3
- package/project/context/flowr-analyzer-dependencies-context.js +9 -14
- package/project/context/flowr-analyzer-files-context.js +15 -17
- package/project/context/flowr-analyzer-meta-context.js +2 -12
- package/project/dependency-version-space.d.ts +1 -7
- package/project/dependency-version-space.js +9 -8
- package/project/flowr-analyzer-builder.d.ts +4 -4
- package/project/flowr-analyzer.d.ts +4 -6
- package/project/flowr-analyzer.js +4 -5
- package/project/plugins/file-plugins/files/flowr-namespace-file.js +22 -34
- package/project/plugins/file-plugins/files/flowr-rda-file.d.ts +13 -13
- package/project/plugins/file-plugins/files/flowr-rda-file.js +131 -286
- package/project/plugins/file-plugins/files/flowr-rmarkdown-file.d.ts +1 -0
- package/project/plugins/file-plugins/files/flowr-rmarkdown-file.js +1 -0
- package/project/plugins/file-plugins/flowr-analyzer-description-file-plugin.d.ts +2 -5
- package/project/plugins/file-plugins/flowr-analyzer-description-file-plugin.js +2 -8
- package/project/plugins/file-plugins/flowr-analyzer-file-plugin.d.ts +32 -0
- package/project/plugins/file-plugins/flowr-analyzer-file-plugin.js +43 -1
- package/project/plugins/file-plugins/flowr-analyzer-inst-file-plugin.d.ts +4 -12
- package/project/plugins/file-plugins/flowr-analyzer-inst-file-plugin.js +3 -16
- package/project/plugins/file-plugins/flowr-analyzer-license-file-plugin.d.ts +5 -8
- package/project/plugins/file-plugins/flowr-analyzer-license-file-plugin.js +4 -10
- package/project/plugins/file-plugins/flowr-analyzer-manifest-file-plugin.d.ts +3 -10
- package/project/plugins/file-plugins/flowr-analyzer-manifest-file-plugin.js +1 -13
- package/project/plugins/file-plugins/flowr-analyzer-namespace-files-plugin.d.ts +3 -6
- package/project/plugins/file-plugins/flowr-analyzer-namespace-files-plugin.js +2 -8
- package/project/plugins/file-plugins/flowr-analyzer-news-file-plugin.d.ts +2 -5
- package/project/plugins/file-plugins/flowr-analyzer-news-file-plugin.js +2 -8
- package/project/plugins/file-plugins/flowr-analyzer-rda-file-plugin.d.ts +2 -5
- package/project/plugins/file-plugins/flowr-analyzer-rda-file-plugin.js +2 -8
- package/project/plugins/file-plugins/flowr-analyzer-rprofile-file-plugin.d.ts +3 -4
- package/project/plugins/file-plugins/flowr-analyzer-rprofile-file-plugin.js +3 -6
- package/project/plugins/file-plugins/flowr-analyzer-test-file-plugin.d.ts +4 -12
- package/project/plugins/file-plugins/flowr-analyzer-test-file-plugin.js +3 -16
- package/project/plugins/file-plugins/flowr-analyzer-vignette-file-plugin.d.ts +4 -12
- package/project/plugins/file-plugins/flowr-analyzer-vignette-file-plugin.js +3 -16
- package/project/plugins/file-plugins/flowr-analyzer-virtualenv-file-plugin.d.ts +4 -12
- package/project/plugins/file-plugins/flowr-analyzer-virtualenv-file-plugin.js +3 -16
- package/project/plugins/file-plugins/notebooks/flowr-analyzer-jupyter-file-plugin.d.ts +2 -5
- package/project/plugins/file-plugins/notebooks/flowr-analyzer-jupyter-file-plugin.js +2 -8
- package/project/plugins/file-plugins/notebooks/flowr-analyzer-rmarkdown-file-plugin.d.ts +2 -6
- package/project/plugins/file-plugins/notebooks/flowr-analyzer-rmarkdown-file-plugin.js +1 -10
- package/project/plugins/file-plugins/notebooks/flowr-analyzer-sweave-file-plugin.d.ts +2 -5
- package/project/plugins/file-plugins/notebooks/flowr-analyzer-sweave-file-plugin.js +2 -8
- package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-library-plugin.js +2 -1
- package/project/sigdb/build.d.ts +2 -2
- package/project/sigdb/decode.d.ts +0 -5
- package/project/sigdb/decode.js +0 -8
- package/project/sigdb/index-format.d.ts +4 -4
- package/project/sigdb/manifest.d.ts +2 -2
- package/project/sigdb/reader.d.ts +54 -13
- package/project/sigdb/reader.js +4 -3
- package/project/sigdb/schema.d.ts +3 -1
- package/project/sigdb/signature-db.d.ts +69 -0
- package/project/sigdb/signature-db.js +54 -0
- package/project/sigdb/signature-match.d.ts +10 -5
- package/project/sigdb/signature-match.js +13 -8
- package/queries/catalog/absint-query/absint-query-executor.js +1 -2
- package/queries/catalog/call-context-query/call-context-query-executor.js +2 -4
- package/queries/catalog/call-context-query/identify-link-to-last-call-relation.d.ts +1 -1
- package/queries/catalog/call-context-query/identify-link-to-last-call-relation.js +33 -6
- package/queries/catalog/control-flow-query/control-flow-query-executor.js +1 -2
- package/queries/catalog/dependencies-query/dependencies-query-executor.js +2 -2
- package/queries/catalog/dependencies-query/dependencies-query-format.d.ts +8 -7
- package/queries/catalog/dependencies-query/dependencies-query-format.js +22 -35
- package/queries/catalog/dependencies-query/function-info/library-functions.d.ts +13 -1
- package/queries/catalog/dependencies-query/function-info/library-functions.js +26 -22
- package/queries/catalog/dependencies-query/function-info/statistics-functions.d.ts +9 -0
- package/queries/catalog/dependencies-query/function-info/statistics-functions.js +19 -0
- package/queries/catalog/dependencies-query/implicit-echo.d.ts +13 -0
- package/queries/catalog/dependencies-query/implicit-echo.js +133 -0
- package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-format.js +2 -2
- package/queries/catalog/happens-before-query/happens-before-query-executor.js +1 -2
- package/queries/catalog/inspect-exceptions-query/inspect-exception-query-format.d.ts +2 -2
- package/queries/catalog/signature-query/signature-query-executor.js +4 -3
- package/queries/catalog/static-slice-query/static-slice-query-format.d.ts +1 -1
- package/r-bridge/lang-4.x/ast/model/nodes/info/r-delimiter.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/info/r-delimiter.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-access.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-access.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-argument.d.ts +4 -1
- package/r-bridge/lang-4.x/ast/model/nodes/r-argument.js +5 -2
- package/r-bridge/lang-4.x/ast/model/nodes/r-binary-op.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-binary-op.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-break.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-break.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-comment.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-comment.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-expression-list.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-expression-list.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-for-loop.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-for-loop.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-function-call.d.ts +6 -4
- package/r-bridge/lang-4.x/ast/model/nodes/r-function-call.js +6 -4
- package/r-bridge/lang-4.x/ast/model/nodes/r-function-definition.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-function-definition.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-if-then-else.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-if-then-else.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-line-directive.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-line-directive.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-logical.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-logical.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-next.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-next.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-number.d.ts +6 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-number.js +13 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-parameter.d.ts +8 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-parameter.js +8 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-pipe.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-pipe.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-project.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-project.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-repeat-loop.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-repeat-loop.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-string.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-string.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-symbol.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-symbol.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-unary-op.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-unary-op.js +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-while-loop.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-while-loop.js +1 -0
- package/r-bridge/lang-4.x/ast/model/processing/decorate.js +2 -1
- package/r-bridge/lang-4.x/ast/model/processing/node-id.d.ts +5 -1
- package/r-bridge/lang-4.x/ast/model/processing/node-id.js +0 -5
- package/r-bridge/lang-4.x/ast/model/processing/stateful-fold.d.ts +1 -1
- package/r-bridge/lang-4.x/ast/model/processing/stateful-fold.js +3 -2
- package/r-bridge/lang-4.x/ast/parser/main/internal/control/normalize-if-then-else.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/control/normalize-if-then.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/expression/normalize-expression.js +1 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/functions/normalize-argument.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/functions/normalize-call.d.ts +2 -2
- package/r-bridge/lang-4.x/ast/parser/main/internal/functions/normalize-call.js +6 -3
- package/r-bridge/lang-4.x/ast/parser/main/internal/functions/normalize-definition.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/functions/normalize-parameter.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/loops/normalize-for.js +5 -3
- package/r-bridge/lang-4.x/ast/parser/main/internal/loops/normalize-repeat.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/loops/normalize-while.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/normalize-access.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/operators/normalize-binary.js +5 -3
- package/r-bridge/lang-4.x/ast/parser/main/internal/operators/normalize-unary.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/structure/normalize-expressions.d.ts +1 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/structure/normalize-expressions.js +2 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/structure/normalize-root.js +3 -1
- package/r-bridge/lang-4.x/ast/parser/main/normalize-meta.d.ts +1 -1
- package/r-bridge/lang-4.x/ast/parser/main/normalize-meta.js +2 -1
- package/r-bridge/lang-4.x/tree-sitter/tree-sitter-normalize.js +5 -3
- package/reconstruct/inline/source-inline-map.js +3 -3
- package/reconstruct/reconstruct.js +6 -4
- package/search/flowr-search-builder.d.ts +8 -8
- package/search/flowr-search-builder.js +4 -4
- package/search/flowr-search-filters.d.ts +2 -2
- package/search/flowr-search-filters.js +3 -2
- package/search/search-executor/search-enrichers.d.ts +6 -0
- package/search/search-executor/search-enrichers.js +44 -5
- package/slicing/criterion/filters/all-variables.js +2 -1
- package/slicing/criterion/parse.js +8 -6
- package/slicing/static/slice-call.js +2 -2
- package/util/arg-matching.d.ts +3 -0
- package/util/arg-matching.js +12 -1
- package/util/collections/arrays.d.ts +0 -4
- package/util/collections/arrays.js +4 -26
- package/util/diff-graph.d.ts +1 -1
- package/util/diff-graph.js +17 -3
- package/util/diff.d.ts +6 -0
- package/util/mermaid/ast.d.ts +1 -1
- package/util/mermaid/ast.js +5 -4
- package/util/mermaid/cfg.js +130 -24
- package/util/mermaid/dfg.js +31 -10
- package/util/mermaid/mermaid.js +2 -0
- package/util/objects.d.ts +24 -4
- package/util/objects.js +12 -0
- package/util/prefix.d.ts +1 -1
- package/util/text/playground-link.d.ts +131 -0
- package/util/text/playground-link.js +214 -0
- package/util/text/strings.js +7 -3
- package/util/version.js +1 -1
- package/control-flow/cfg-builder.d.ts +0 -30
- package/control-flow/cfg-builder.js +0 -79
- package/control-flow/extract-cfg.d.ts +0 -36
- package/control-flow/extract-cfg.js +0 -693
- package/project/cfg-kind.d.ts +0 -21
- package/project/cfg-kind.js +0 -26
|
@@ -8,7 +8,8 @@ const vertex_1 = require("../dataflow/graph/vertex");
|
|
|
8
8
|
const info_1 = require("../dataflow/info");
|
|
9
9
|
const r_function_call_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-function-call");
|
|
10
10
|
const assert_1 = require("../util/assert");
|
|
11
|
-
const
|
|
11
|
+
const visitor_1 = require("../r-bridge/lang-4.x/ast/model/processing/visitor");
|
|
12
|
+
const r_function_definition_1 = require("../r-bridge/lang-4.x/ast/model/nodes/r-function-definition");
|
|
12
13
|
const semantic_cfg_guided_visitor_1 = require("./semantic-cfg-guided-visitor");
|
|
13
14
|
const built_in_proc_name_1 = require("../dataflow/environments/built-in-proc-name");
|
|
14
15
|
exports.loopyFunctions = new Set([built_in_proc_name_1.BuiltInProcName.ForLoop, built_in_proc_name_1.BuiltInProcName.WhileLoop, built_in_proc_name_1.BuiltInProcName.RepeatLoop]);
|
|
@@ -66,20 +67,23 @@ class CfgSingleIterationLoopDetector extends semantic_cfg_guided_visitor_1.Seman
|
|
|
66
67
|
}
|
|
67
68
|
startVisitor(_) {
|
|
68
69
|
const g = this.config.controlFlow.graph;
|
|
69
|
-
const
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
continue;
|
|
70
|
+
const loopNode = this.getNormalizedAst(this.loopToCheck);
|
|
71
|
+
(0, assert_1.guard)(loopNode !== undefined, "Can't find the loop to check");
|
|
72
|
+
const withinLoop = [];
|
|
73
|
+
new visitor_1.NodeVisitor(node => {
|
|
74
|
+
if (r_function_definition_1.RFunctionDefinition.is(node)) {
|
|
75
|
+
/* a jump within a nested closure leaves that closure, not the loop around it */
|
|
76
|
+
return true;
|
|
77
77
|
}
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
78
|
+
withinLoop.push(node.info.id);
|
|
79
|
+
}).visit(loopNode);
|
|
80
|
+
/*
|
|
81
|
+
* Everything the loop is made of is inspected rather than followed through the graph: a loop that always
|
|
82
|
+
* jumps out never reaches its own vertex, so a walk from there would not find what breaks it.
|
|
83
|
+
*/
|
|
84
|
+
for (const current of withinLoop) {
|
|
85
|
+
if (!g.hasVertex(current) || !this.visitNode(current)) {
|
|
86
|
+
continue;
|
|
83
87
|
}
|
|
84
88
|
this.onlyLoopyOnce ||= this.encounteredLoopBreaker && (0, info_1.happensInEveryBranch)(this.loopCds?.filter(c => !c.byIteration));
|
|
85
89
|
}
|
|
@@ -9,9 +9,7 @@ declare function processor(results: {
|
|
|
9
9
|
}, input: {
|
|
10
10
|
parser?: Parser<KnownParserType>;
|
|
11
11
|
context?: FlowrAnalyzerContext;
|
|
12
|
-
}): import("../../../../dataflow/info").DataflowInformation
|
|
13
|
-
cfgQuick: import("../../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
14
|
-
};
|
|
12
|
+
}): import("../../../../dataflow/info").DataflowInformation;
|
|
15
13
|
export declare const STATIC_DATAFLOW: {
|
|
16
14
|
readonly humanReadableName: "dataflow";
|
|
17
15
|
readonly processor: typeof processor;
|
|
@@ -7,6 +7,26 @@ import { PipelineExecutor } from '../../pipeline-executor';
|
|
|
7
7
|
import type { RShell } from '../../../r-bridge/shell';
|
|
8
8
|
import type { TreeSitterExecutor } from '../../../r-bridge/lang-4.x/tree-sitter/tree-sitter-executor';
|
|
9
9
|
export declare const DEFAULT_SLICING_PIPELINE: import("./pipeline").Pipeline<{
|
|
10
|
+
readonly humanReadableName: "dataflow";
|
|
11
|
+
readonly processor: (results: {
|
|
12
|
+
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
13
|
+
}, input: {
|
|
14
|
+
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
15
|
+
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
16
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
17
|
+
readonly requiredInput: {};
|
|
18
|
+
readonly name: "dataflow";
|
|
19
|
+
readonly description: "Construct the dataflow graph";
|
|
20
|
+
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
21
|
+
readonly printer: {
|
|
22
|
+
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
23
|
+
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
24
|
+
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
25
|
+
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
26
|
+
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
27
|
+
};
|
|
28
|
+
readonly dependencies: readonly ["normalize"];
|
|
29
|
+
} | {
|
|
10
30
|
readonly name: "parse";
|
|
11
31
|
readonly humanReadableName: "parse with R shell";
|
|
12
32
|
readonly description: "Parse the given R code into an AST";
|
|
@@ -39,28 +59,6 @@ export declare const DEFAULT_SLICING_PIPELINE: import("./pipeline").Pipeline<{
|
|
|
39
59
|
};
|
|
40
60
|
readonly dependencies: readonly ["parse"];
|
|
41
61
|
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
42
|
-
} | {
|
|
43
|
-
readonly humanReadableName: "dataflow";
|
|
44
|
-
readonly processor: (results: {
|
|
45
|
-
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
46
|
-
}, input: {
|
|
47
|
-
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
48
|
-
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
49
|
-
}) => import("../../../dataflow/info").DataflowInformation & {
|
|
50
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
51
|
-
};
|
|
52
|
-
readonly requiredInput: {};
|
|
53
|
-
readonly name: "dataflow";
|
|
54
|
-
readonly description: "Construct the dataflow graph";
|
|
55
|
-
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
56
|
-
readonly printer: {
|
|
57
|
-
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
58
|
-
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
59
|
-
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
60
|
-
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
61
|
-
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
62
|
-
};
|
|
63
|
-
readonly dependencies: readonly ["normalize"];
|
|
64
62
|
} | {
|
|
65
63
|
readonly name: "slice";
|
|
66
64
|
readonly humanReadableName: "static slice";
|
|
@@ -92,6 +90,26 @@ export declare const DEFAULT_SLICING_PIPELINE: import("./pipeline").Pipeline<{
|
|
|
92
90
|
readonly requiredInput: import("../all/static-slicing/10-reconstruct").ReconstructRequiredInput;
|
|
93
91
|
}>;
|
|
94
92
|
export declare const DEFAULT_SLICE_AND_RECONSTRUCT_PIPELINE: import("./pipeline").Pipeline<{
|
|
93
|
+
readonly humanReadableName: "dataflow";
|
|
94
|
+
readonly processor: (results: {
|
|
95
|
+
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
96
|
+
}, input: {
|
|
97
|
+
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
98
|
+
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
99
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
100
|
+
readonly requiredInput: {};
|
|
101
|
+
readonly name: "dataflow";
|
|
102
|
+
readonly description: "Construct the dataflow graph";
|
|
103
|
+
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
104
|
+
readonly printer: {
|
|
105
|
+
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
106
|
+
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
107
|
+
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
108
|
+
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
109
|
+
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
110
|
+
};
|
|
111
|
+
readonly dependencies: readonly ["normalize"];
|
|
112
|
+
} | {
|
|
95
113
|
readonly name: "parse";
|
|
96
114
|
readonly humanReadableName: "parse with R shell";
|
|
97
115
|
readonly description: "Parse the given R code into an AST";
|
|
@@ -124,28 +142,6 @@ export declare const DEFAULT_SLICE_AND_RECONSTRUCT_PIPELINE: import("./pipeline"
|
|
|
124
142
|
};
|
|
125
143
|
readonly dependencies: readonly ["parse"];
|
|
126
144
|
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
127
|
-
} | {
|
|
128
|
-
readonly humanReadableName: "dataflow";
|
|
129
|
-
readonly processor: (results: {
|
|
130
|
-
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
131
|
-
}, input: {
|
|
132
|
-
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
133
|
-
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
134
|
-
}) => import("../../../dataflow/info").DataflowInformation & {
|
|
135
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
136
|
-
};
|
|
137
|
-
readonly requiredInput: {};
|
|
138
|
-
readonly name: "dataflow";
|
|
139
|
-
readonly description: "Construct the dataflow graph";
|
|
140
|
-
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
141
|
-
readonly printer: {
|
|
142
|
-
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
143
|
-
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
144
|
-
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
145
|
-
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
146
|
-
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
147
|
-
};
|
|
148
|
-
readonly dependencies: readonly ["normalize"];
|
|
149
145
|
} | {
|
|
150
146
|
readonly name: "slice";
|
|
151
147
|
readonly humanReadableName: "static slice";
|
|
@@ -177,6 +173,26 @@ export declare const DEFAULT_SLICE_AND_RECONSTRUCT_PIPELINE: import("./pipeline"
|
|
|
177
173
|
readonly requiredInput: import("../all/static-slicing/10-reconstruct").ReconstructRequiredInput;
|
|
178
174
|
}>;
|
|
179
175
|
export declare const DEFAULT_SLICE_WITHOUT_RECONSTRUCT_PIPELINE: import("./pipeline").Pipeline<{
|
|
176
|
+
readonly humanReadableName: "dataflow";
|
|
177
|
+
readonly processor: (results: {
|
|
178
|
+
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
179
|
+
}, input: {
|
|
180
|
+
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
181
|
+
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
182
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
183
|
+
readonly requiredInput: {};
|
|
184
|
+
readonly name: "dataflow";
|
|
185
|
+
readonly description: "Construct the dataflow graph";
|
|
186
|
+
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
187
|
+
readonly printer: {
|
|
188
|
+
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
189
|
+
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
190
|
+
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
191
|
+
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
192
|
+
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
193
|
+
};
|
|
194
|
+
readonly dependencies: readonly ["normalize"];
|
|
195
|
+
} | {
|
|
180
196
|
readonly name: "parse";
|
|
181
197
|
readonly humanReadableName: "parse with R shell";
|
|
182
198
|
readonly description: "Parse the given R code into an AST";
|
|
@@ -209,28 +225,6 @@ export declare const DEFAULT_SLICE_WITHOUT_RECONSTRUCT_PIPELINE: import("./pipel
|
|
|
209
225
|
};
|
|
210
226
|
readonly dependencies: readonly ["parse"];
|
|
211
227
|
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
212
|
-
} | {
|
|
213
|
-
readonly humanReadableName: "dataflow";
|
|
214
|
-
readonly processor: (results: {
|
|
215
|
-
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
216
|
-
}, input: {
|
|
217
|
-
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
218
|
-
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
219
|
-
}) => import("../../../dataflow/info").DataflowInformation & {
|
|
220
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
221
|
-
};
|
|
222
|
-
readonly requiredInput: {};
|
|
223
|
-
readonly name: "dataflow";
|
|
224
|
-
readonly description: "Construct the dataflow graph";
|
|
225
|
-
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
226
|
-
readonly printer: {
|
|
227
|
-
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
228
|
-
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
229
|
-
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
230
|
-
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
231
|
-
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
232
|
-
};
|
|
233
|
-
readonly dependencies: readonly ["normalize"];
|
|
234
228
|
} | {
|
|
235
229
|
readonly name: "slice";
|
|
236
230
|
readonly humanReadableName: "static slice";
|
|
@@ -247,15 +241,45 @@ export declare const DEFAULT_SLICE_WITHOUT_RECONSTRUCT_PIPELINE: import("./pipel
|
|
|
247
241
|
readonly requiredInput: import("../all/static-slicing/00-slice").SliceRequiredInput;
|
|
248
242
|
}>;
|
|
249
243
|
export declare const TREE_SITTER_SLICING_PIPELINE: import("./pipeline").Pipeline<{
|
|
244
|
+
readonly name: "parse";
|
|
245
|
+
readonly humanReadableName: "parse with tree-sitter";
|
|
246
|
+
readonly description: "Parse the given R code into an AST using tree-sitter";
|
|
247
|
+
readonly processor: (_results: unknown, input: Partial<import("../../../r-bridge/parser").ParseRequiredInput<import("web-tree-sitter").Tree>>) => Promise<import("../../../r-bridge/parser").ParseStepOutput<import("web-tree-sitter").Tree>>;
|
|
248
|
+
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
249
|
+
readonly printer: {
|
|
250
|
+
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
251
|
+
readonly 2: {
|
|
252
|
+
(value: any, replacer?: (this: any, key: string, value: any) => any, space?: string | number): string;
|
|
253
|
+
(value: any, replacer?: (number | string)[] | null, space?: string | number): string;
|
|
254
|
+
};
|
|
255
|
+
};
|
|
256
|
+
readonly dependencies: readonly [];
|
|
257
|
+
readonly requiredInput: import("../../../r-bridge/parser").ParseRequiredInput<import("web-tree-sitter").Tree>;
|
|
258
|
+
} | {
|
|
259
|
+
readonly name: "normalize";
|
|
260
|
+
readonly humanReadableName: "normalize tree-sitter tree";
|
|
261
|
+
readonly description: "Normalize the AST to flowR's AST";
|
|
262
|
+
readonly processor: (results: {
|
|
263
|
+
parse?: import("../../../r-bridge/parser").ParseStepOutput<import("web-tree-sitter").Tree>;
|
|
264
|
+
}, input: Partial<import("../all/core/10-normalize").NormalizeRequiredInput>) => import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst<import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../../../r-bridge/lang-4.x/ast/model/nodes/r-project").RProject<import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>>;
|
|
265
|
+
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
266
|
+
readonly printer: {
|
|
267
|
+
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
268
|
+
readonly 2: typeof import("../../print/normalize-printer").normalizedAstToJson;
|
|
269
|
+
readonly 5: typeof import("../../print/normalize-printer").normalizedAstToQuads;
|
|
270
|
+
readonly 3: typeof import("../../print/normalize-printer").printNormalizedAstToMermaid;
|
|
271
|
+
readonly 4: typeof import("../../print/normalize-printer").printNormalizedAstToMermaidUrl;
|
|
272
|
+
};
|
|
273
|
+
readonly dependencies: readonly ["parse"];
|
|
274
|
+
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
275
|
+
} | {
|
|
250
276
|
readonly humanReadableName: "dataflow";
|
|
251
277
|
readonly processor: (results: {
|
|
252
278
|
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
253
279
|
}, input: {
|
|
254
280
|
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
255
281
|
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
256
|
-
}) => import("../../../dataflow/info").DataflowInformation
|
|
257
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
258
|
-
};
|
|
282
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
259
283
|
readonly requiredInput: {};
|
|
260
284
|
readonly name: "dataflow";
|
|
261
285
|
readonly description: "Construct the dataflow graph";
|
|
@@ -297,7 +321,8 @@ export declare const TREE_SITTER_SLICING_PIPELINE: import("./pipeline").Pipeline
|
|
|
297
321
|
};
|
|
298
322
|
readonly dependencies: readonly ["slice"];
|
|
299
323
|
readonly requiredInput: import("../all/static-slicing/10-reconstruct").ReconstructRequiredInput;
|
|
300
|
-
}
|
|
324
|
+
}>;
|
|
325
|
+
export declare const TREE_SITTER_SLICE_AND_RECONSTRUCT_PIPELINE: import("./pipeline").Pipeline<{
|
|
301
326
|
readonly name: "parse";
|
|
302
327
|
readonly humanReadableName: "parse with tree-sitter";
|
|
303
328
|
readonly description: "Parse the given R code into an AST using tree-sitter";
|
|
@@ -329,17 +354,14 @@ export declare const TREE_SITTER_SLICING_PIPELINE: import("./pipeline").Pipeline
|
|
|
329
354
|
};
|
|
330
355
|
readonly dependencies: readonly ["parse"];
|
|
331
356
|
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
332
|
-
}
|
|
333
|
-
export declare const TREE_SITTER_SLICE_AND_RECONSTRUCT_PIPELINE: import("./pipeline").Pipeline<{
|
|
357
|
+
} | {
|
|
334
358
|
readonly humanReadableName: "dataflow";
|
|
335
359
|
readonly processor: (results: {
|
|
336
360
|
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
337
361
|
}, input: {
|
|
338
362
|
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
339
363
|
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
340
|
-
}) => import("../../../dataflow/info").DataflowInformation
|
|
341
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
342
|
-
};
|
|
364
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
343
365
|
readonly requiredInput: {};
|
|
344
366
|
readonly name: "dataflow";
|
|
345
367
|
readonly description: "Construct the dataflow graph";
|
|
@@ -381,7 +403,8 @@ export declare const TREE_SITTER_SLICE_AND_RECONSTRUCT_PIPELINE: import("./pipel
|
|
|
381
403
|
};
|
|
382
404
|
readonly dependencies: readonly ["slice"];
|
|
383
405
|
readonly requiredInput: import("../all/static-slicing/10-reconstruct").ReconstructRequiredInput;
|
|
384
|
-
}
|
|
406
|
+
}>;
|
|
407
|
+
export declare const TREE_SITTER_SLICE_WITHOUT_RECONSTRUCT_PIPELINE: import("./pipeline").Pipeline<{
|
|
385
408
|
readonly name: "parse";
|
|
386
409
|
readonly humanReadableName: "parse with tree-sitter";
|
|
387
410
|
readonly description: "Parse the given R code into an AST using tree-sitter";
|
|
@@ -413,17 +436,14 @@ export declare const TREE_SITTER_SLICE_AND_RECONSTRUCT_PIPELINE: import("./pipel
|
|
|
413
436
|
};
|
|
414
437
|
readonly dependencies: readonly ["parse"];
|
|
415
438
|
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
416
|
-
}
|
|
417
|
-
export declare const TREE_SITTER_SLICE_WITHOUT_RECONSTRUCT_PIPELINE: import("./pipeline").Pipeline<{
|
|
439
|
+
} | {
|
|
418
440
|
readonly humanReadableName: "dataflow";
|
|
419
441
|
readonly processor: (results: {
|
|
420
442
|
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
421
443
|
}, input: {
|
|
422
444
|
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
423
445
|
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
424
|
-
}) => import("../../../dataflow/info").DataflowInformation
|
|
425
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
426
|
-
};
|
|
446
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
427
447
|
readonly requiredInput: {};
|
|
428
448
|
readonly name: "dataflow";
|
|
429
449
|
readonly description: "Construct the dataflow graph";
|
|
@@ -450,38 +470,6 @@ export declare const TREE_SITTER_SLICE_WITHOUT_RECONSTRUCT_PIPELINE: import("./p
|
|
|
450
470
|
};
|
|
451
471
|
readonly dependencies: readonly ["dataflow"];
|
|
452
472
|
readonly requiredInput: import("../all/static-slicing/00-slice").SliceRequiredInput;
|
|
453
|
-
} | {
|
|
454
|
-
readonly name: "parse";
|
|
455
|
-
readonly humanReadableName: "parse with tree-sitter";
|
|
456
|
-
readonly description: "Parse the given R code into an AST using tree-sitter";
|
|
457
|
-
readonly processor: (_results: unknown, input: Partial<import("../../../r-bridge/parser").ParseRequiredInput<import("web-tree-sitter").Tree>>) => Promise<import("../../../r-bridge/parser").ParseStepOutput<import("web-tree-sitter").Tree>>;
|
|
458
|
-
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
459
|
-
readonly printer: {
|
|
460
|
-
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
461
|
-
readonly 2: {
|
|
462
|
-
(value: any, replacer?: (this: any, key: string, value: any) => any, space?: string | number): string;
|
|
463
|
-
(value: any, replacer?: (number | string)[] | null, space?: string | number): string;
|
|
464
|
-
};
|
|
465
|
-
};
|
|
466
|
-
readonly dependencies: readonly [];
|
|
467
|
-
readonly requiredInput: import("../../../r-bridge/parser").ParseRequiredInput<import("web-tree-sitter").Tree>;
|
|
468
|
-
} | {
|
|
469
|
-
readonly name: "normalize";
|
|
470
|
-
readonly humanReadableName: "normalize tree-sitter tree";
|
|
471
|
-
readonly description: "Normalize the AST to flowR's AST";
|
|
472
|
-
readonly processor: (results: {
|
|
473
|
-
parse?: import("../../../r-bridge/parser").ParseStepOutput<import("web-tree-sitter").Tree>;
|
|
474
|
-
}, input: Partial<import("../all/core/10-normalize").NormalizeRequiredInput>) => import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst<import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation, import("../../../r-bridge/lang-4.x/ast/model/nodes/r-project").RProject<import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").ParentInformation>>;
|
|
475
|
-
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
476
|
-
readonly printer: {
|
|
477
|
-
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
478
|
-
readonly 2: typeof import("../../print/normalize-printer").normalizedAstToJson;
|
|
479
|
-
readonly 5: typeof import("../../print/normalize-printer").normalizedAstToQuads;
|
|
480
|
-
readonly 3: typeof import("../../print/normalize-printer").printNormalizedAstToMermaid;
|
|
481
|
-
readonly 4: typeof import("../../print/normalize-printer").printNormalizedAstToMermaidUrl;
|
|
482
|
-
};
|
|
483
|
-
readonly dependencies: readonly ["parse"];
|
|
484
|
-
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
485
473
|
}>;
|
|
486
474
|
/**
|
|
487
475
|
* The default pipeline for working with flowR, including the dataflow step.
|
|
@@ -489,6 +477,26 @@ export declare const TREE_SITTER_SLICE_WITHOUT_RECONSTRUCT_PIPELINE: import("./p
|
|
|
489
477
|
* and the {@link DEFAULT_SLICE_AND_RECONSTRUCT_PIPELINE} for the pipeline with slicing and reconstructing steps
|
|
490
478
|
*/
|
|
491
479
|
export declare const DEFAULT_DATAFLOW_PIPELINE: import("./pipeline").Pipeline<{
|
|
480
|
+
readonly humanReadableName: "dataflow";
|
|
481
|
+
readonly processor: (results: {
|
|
482
|
+
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
483
|
+
}, input: {
|
|
484
|
+
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
485
|
+
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
486
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
487
|
+
readonly requiredInput: {};
|
|
488
|
+
readonly name: "dataflow";
|
|
489
|
+
readonly description: "Construct the dataflow graph";
|
|
490
|
+
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
491
|
+
readonly printer: {
|
|
492
|
+
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
493
|
+
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
494
|
+
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
495
|
+
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
496
|
+
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
497
|
+
};
|
|
498
|
+
readonly dependencies: readonly ["normalize"];
|
|
499
|
+
} | {
|
|
492
500
|
readonly name: "parse";
|
|
493
501
|
readonly humanReadableName: "parse with R shell";
|
|
494
502
|
readonly description: "Parse the given R code into an AST";
|
|
@@ -521,52 +529,8 @@ export declare const DEFAULT_DATAFLOW_PIPELINE: import("./pipeline").Pipeline<{
|
|
|
521
529
|
};
|
|
522
530
|
readonly dependencies: readonly ["parse"];
|
|
523
531
|
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
524
|
-
} | {
|
|
525
|
-
readonly humanReadableName: "dataflow";
|
|
526
|
-
readonly processor: (results: {
|
|
527
|
-
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
528
|
-
}, input: {
|
|
529
|
-
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
530
|
-
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
531
|
-
}) => import("../../../dataflow/info").DataflowInformation & {
|
|
532
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
533
|
-
};
|
|
534
|
-
readonly requiredInput: {};
|
|
535
|
-
readonly name: "dataflow";
|
|
536
|
-
readonly description: "Construct the dataflow graph";
|
|
537
|
-
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
538
|
-
readonly printer: {
|
|
539
|
-
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
540
|
-
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
541
|
-
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
542
|
-
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
543
|
-
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
544
|
-
};
|
|
545
|
-
readonly dependencies: readonly ["normalize"];
|
|
546
532
|
}>;
|
|
547
533
|
export declare const TREE_SITTER_DATAFLOW_PIPELINE: import("./pipeline").Pipeline<{
|
|
548
|
-
readonly humanReadableName: "dataflow";
|
|
549
|
-
readonly processor: (results: {
|
|
550
|
-
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
551
|
-
}, input: {
|
|
552
|
-
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
553
|
-
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
554
|
-
}) => import("../../../dataflow/info").DataflowInformation & {
|
|
555
|
-
cfgQuick: import("../../../control-flow/control-flow-graph").ControlFlowInformation | undefined;
|
|
556
|
-
};
|
|
557
|
-
readonly requiredInput: {};
|
|
558
|
-
readonly name: "dataflow";
|
|
559
|
-
readonly description: "Construct the dataflow graph";
|
|
560
|
-
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
561
|
-
readonly printer: {
|
|
562
|
-
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
563
|
-
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
564
|
-
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
565
|
-
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
566
|
-
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
567
|
-
};
|
|
568
|
-
readonly dependencies: readonly ["normalize"];
|
|
569
|
-
} | {
|
|
570
534
|
readonly name: "parse";
|
|
571
535
|
readonly humanReadableName: "parse with tree-sitter";
|
|
572
536
|
readonly description: "Parse the given R code into an AST using tree-sitter";
|
|
@@ -598,6 +562,26 @@ export declare const TREE_SITTER_DATAFLOW_PIPELINE: import("./pipeline").Pipelin
|
|
|
598
562
|
};
|
|
599
563
|
readonly dependencies: readonly ["parse"];
|
|
600
564
|
readonly requiredInput: import("../all/core/10-normalize").NormalizeRequiredInput;
|
|
565
|
+
} | {
|
|
566
|
+
readonly humanReadableName: "dataflow";
|
|
567
|
+
readonly processor: (results: {
|
|
568
|
+
normalize?: import("../../../r-bridge/lang-4.x/ast/model/processing/decorate").NormalizedAst;
|
|
569
|
+
}, input: {
|
|
570
|
+
parser?: Parser<import("../../../r-bridge/parser").KnownParserType>;
|
|
571
|
+
context?: import("../../../project/context/flowr-analyzer-context").FlowrAnalyzerContext;
|
|
572
|
+
}) => import("../../../dataflow/info").DataflowInformation;
|
|
573
|
+
readonly requiredInput: {};
|
|
574
|
+
readonly name: "dataflow";
|
|
575
|
+
readonly description: "Construct the dataflow graph";
|
|
576
|
+
readonly executed: import("../pipeline-step").PipelineStepStage.OncePerFile;
|
|
577
|
+
readonly printer: {
|
|
578
|
+
readonly 0: typeof import("../../print/print").internalPrinter;
|
|
579
|
+
readonly 2: typeof import("../../print/dataflow-printer").dataflowGraphToJson;
|
|
580
|
+
readonly 5: typeof import("../../print/dataflow-printer").dataflowGraphToQuads;
|
|
581
|
+
readonly 3: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
582
|
+
readonly 4: (this: void, graph: import("../../../dataflow/graph/graph").DataflowGraph | import("../../../dataflow/info").DataflowInformation, includeEnvironments?: boolean, mark?: ReadonlySet<import("../../../r-bridge/lang-4.x/ast/model/processing/node-id").NodeId>, simplified?: boolean, qualifyBaseR?: boolean) => string;
|
|
583
|
+
};
|
|
584
|
+
readonly dependencies: readonly ["normalize"];
|
|
601
585
|
}>;
|
|
602
586
|
/** The pipeline to use when you want to parse and normalize your R file, see {@link DEFAULT_DATAFLOW_PIPELINE} for the additional `dataflow` step */
|
|
603
587
|
export declare const DEFAULT_NORMALIZE_PIPELINE: import("./pipeline").Pipeline<{
|
package/dataflow/cluster.js
CHANGED
|
@@ -19,6 +19,9 @@ function findAllClusters(graph) {
|
|
|
19
19
|
const incoming = new Map();
|
|
20
20
|
for (const [source, outgoing] of graph.edges()) {
|
|
21
21
|
for (const [target, edge] of outgoing) {
|
|
22
|
+
if (edge_1.DfEdge.isOnlyControlFlow(edge)) {
|
|
23
|
+
continue;
|
|
24
|
+
}
|
|
22
25
|
const into = incoming.get(target);
|
|
23
26
|
if (into === undefined) {
|
|
24
27
|
incoming.set(target, new Map([[source, edge]]));
|
|
@@ -64,6 +67,10 @@ function makeCluster(graph, from, notReached, incoming) {
|
|
|
64
67
|
// cluster adjacent edges
|
|
65
68
|
for (const edges of [graph.outgoingEdges(current), incoming.get(current)]) {
|
|
66
69
|
for (const [dest, e] of edges ?? []) {
|
|
70
|
+
/* control flow connects every statement of a program, so clustering along it would yield one cluster */
|
|
71
|
+
if (edge_1.DfEdge.isOnlyControlFlow(e)) {
|
|
72
|
+
continue;
|
|
73
|
+
}
|
|
67
74
|
// don't cluster for function content if it isn't returned
|
|
68
75
|
if (edge_1.DfEdge.doesNotIncludeType(e, edge_1.EdgeType.Returns) && info.onlyBuiltin && info.name === '{') {
|
|
69
76
|
continue;
|
|
@@ -19,3 +19,9 @@ export declare function cancelRevivedKills(kills: readonly KillReference[], writ
|
|
|
19
19
|
export declare function applyKills(env: REnvironmentInformation, kills: readonly KillReference[] | undefined): REnvironmentInformation;
|
|
20
20
|
/** Attaches `cds` to a list of kills, turning them into conditional (maybe) kills. */
|
|
21
21
|
export declare function makeKillsMaybe(kills: readonly KillReference[] | undefined, cds: readonly ControlDependency[]): KillReference[];
|
|
22
|
+
/**
|
|
23
|
+
* Drops the writes that a still-effective removal undid: a definite `named` kill takes out its own name and a
|
|
24
|
+
* definite wholesale kill takes out every name it did not spare. Conditional and `unknown` kills leave the (now
|
|
25
|
+
* maybe) definition in place, as it may still be visible afterwards.
|
|
26
|
+
*/
|
|
27
|
+
export declare function dropKilledWrites(out: readonly IdentifierReference[], kills: readonly KillReference[] | undefined): readonly IdentifierReference[];
|