@eagleoutice/flowr 2.17.4 → 2.17.6
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 +12 -89
- package/abstract-interpretation/absint-inference.d.ts +4 -4
- package/abstract-interpretation/absint-inference.js +12 -13
- package/abstract-interpretation/abstract-semantics.d.ts +2 -1
- package/abstract-interpretation/branch-paths-interpreter.js +60 -0
- package/abstract-interpretation/branch-paths.d.ts +60 -0
- package/abstract-interpretation/branch-paths.js +120 -0
- package/abstract-interpretation/data-frame/arguments.d.ts +14 -3
- package/abstract-interpretation/data-frame/arguments.js +34 -0
- package/abstract-interpretation/data-frame/dataframe-semantics.d.ts +6 -1
- package/abstract-interpretation/data-frame/dataframe-semantics.js +67 -16
- package/abstract-interpretation/data-frame/resolve-args.d.ts +2 -2
- package/abstract-interpretation/data-frame/semantics.d.ts +8 -1
- package/abstract-interpretation/data-frame/semantics.js +18 -16
- package/abstract-interpretation/domains/bounded-set-domain.d.ts +1 -1
- package/abstract-interpretation/domains/state-abstract-domain.js +28 -18
- package/abstract-interpretation/domains/state-map.d.ts +43 -0
- package/abstract-interpretation/domains/state-map.js +147 -0
- package/benchmark/slicer.d.ts +1 -1
- package/benchmark/slicer.js +8 -7
- package/cli/repl/commands/repl-dataflow.js +5 -5
- package/cli/repl/commands/repl-execute.js +3 -2
- package/cli/repl/commands/repl-parse.js +2 -1
- package/cli/repl/core.js +51 -0
- package/cli/repl/print-version.d.ts +1 -1
- package/cli/repl/print-version.js +2 -1
- package/cli/repl/server/connection.d.ts +1 -1
- package/cli/repl/server/connection.js +7 -9
- package/cli/slicer-app.js +2 -1
- package/clones/algorithms/baxter-ast.d.ts +33 -0
- package/clones/algorithms/baxter-ast.js +70 -0
- package/clones/algorithms/greedy-string-tiling.d.ts +17 -0
- package/clones/algorithms/greedy-string-tiling.js +56 -0
- package/clones/algorithms/winnowing.d.ts +27 -0
- package/clones/algorithms/winnowing.js +66 -0
- package/clones/clone-ast.d.ts +75 -0
- package/clones/clone-ast.js +174 -0
- package/clones/clone-dataflow.d.ts +11 -0
- package/clones/clone-dataflow.js +83 -0
- package/clones/clone-detector.d.ts +116 -0
- package/clones/clone-detector.js +200 -0
- package/clones/clone-index.d.ts +54 -0
- package/clones/clone-index.js +56 -0
- package/config.d.ts +21 -2
- package/config.js +7 -1
- package/control-flow/basic-cfg-guided-visitor.js +1 -2
- package/control-flow/cfg-dead-code.js +12 -7
- package/control-flow/happens-before.d.ts +2 -0
- package/control-flow/happens-before.js +15 -9
- package/control-flow/simple-visitor.js +2 -4
- package/core/steps/all/core/00-parse.js +2 -1
- package/core/steps/all/core/01-parse-tree-sitter.js +2 -1
- package/core/steps/all/core/10-normalize.js +2 -1
- package/core/steps/all/core/11-normalize-tree-sitter.js +2 -1
- package/core/steps/all/static-slicing/00-slice.js +2 -1
- package/core/steps/all/static-slicing/10-reconstruct.js +2 -1
- package/core/steps/pipeline/create-pipeline.js +1 -2
- package/core/steps/pipeline/default-pipelines.d.ts +1 -1
- package/core/steps/pipeline/default-pipelines.js +5 -4
- package/core/steps/pipeline-step.d.ts +3 -1
- package/core/steps/pipeline-step.js +5 -0
- package/data/packed.d.ts +10 -0
- package/data/packed.js +33 -0
- package/data/r-base-guards.generated.d.ts +7 -0
- package/data/r-base-guards.generated.js +12 -0
- package/data/r-base-primitives.generated.d.ts +2 -1
- package/data/r-datasets.generated.d.ts +4 -0
- package/data/r-datasets.generated.js +10 -0
- package/data/r-formals.generated.d.ts +4 -0
- package/data/r-formals.generated.js +10 -0
- package/data/r-group-method-guards.generated.d.ts +3 -0
- package/data/r-group-method-guards.generated.js +8 -0
- package/dataflow/cluster.js +1 -2
- package/dataflow/environments/ambient-effect.d.ts +1000 -0
- package/dataflow/environments/ambient-effect.js +234 -0
- package/dataflow/environments/ambient-state-name.d.ts +59 -24
- package/dataflow/environments/ambient-state-name.js +65 -21
- package/dataflow/environments/apply-kill.d.ts +9 -20
- package/dataflow/environments/apply-kill.js +62 -29
- package/dataflow/environments/built-in-config.d.ts +7 -15
- package/dataflow/environments/built-in-config.js +15 -16
- package/dataflow/environments/built-in-eval-name.d.ts +5 -6
- package/dataflow/environments/built-in-eval-name.js +4 -5
- package/dataflow/environments/built-in-kinds.d.ts +69 -0
- package/dataflow/environments/built-in-kinds.js +39 -0
- package/dataflow/environments/built-in-proc-name.d.ts +4 -0
- package/dataflow/environments/built-in-proc-name.js +11 -0
- package/dataflow/environments/built-in-props.d.ts +75 -176
- package/dataflow/environments/built-in-props.js +53 -157
- package/dataflow/environments/built-in.d.ts +42 -73
- package/dataflow/environments/built-in.js +49 -93
- package/dataflow/environments/data-masking-functions.d.ts +2 -2
- package/dataflow/environments/default-builtin-config/base-functions.d.ts +7 -0
- package/dataflow/environments/default-builtin-config/base-functions.js +397 -0
- package/dataflow/environments/default-builtin-config/base-language.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/base-language.js +69 -0
- package/dataflow/environments/default-builtin-config/base-operators.d.ts +58 -0
- package/dataflow/environments/default-builtin-config/base-operators.js +169 -0
- package/dataflow/environments/default-builtin-config/database-access.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/database-access.js +16 -0
- package/dataflow/environments/default-builtin-config/define-helpers.d.ts +45 -0
- package/dataflow/environments/default-builtin-config/define-helpers.js +50 -0
- package/dataflow/environments/default-builtin-config/dev-tooling.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/dev-tooling.js +63 -0
- package/dataflow/environments/default-builtin-config/file-io.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/file-io.js +83 -0
- package/dataflow/environments/default-builtin-config/graphics-devices.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/graphics-devices.js +67 -0
- package/dataflow/environments/default-builtin-config/guard-builders.d.ts +16 -0
- package/dataflow/environments/default-builtin-config/guard-builders.js +29 -0
- package/dataflow/environments/default-builtin-config/guards-primitive-lang.d.ts +15 -0
- package/dataflow/environments/default-builtin-config/guards-primitive-lang.js +228 -0
- package/dataflow/environments/default-builtin-config/guards-primitive-ops.d.ts +11 -0
- package/dataflow/environments/default-builtin-config/guards-primitive-ops.js +154 -0
- package/dataflow/environments/default-builtin-config/guards.d.ts +9 -0
- package/dataflow/environments/default-builtin-config/guards.js +211 -0
- package/dataflow/environments/default-builtin-config/index.d.ts +18 -0
- package/dataflow/environments/default-builtin-config/index.js +129 -0
- package/dataflow/environments/default-builtin-config/media-formats.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/media-formats.js +41 -0
- package/dataflow/environments/default-builtin-config/misc-packages.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/misc-packages.js +18 -0
- package/dataflow/environments/default-builtin-config/network-access.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/network-access.js +47 -0
- package/dataflow/environments/default-builtin-config/object-systems.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/object-systems.js +39 -0
- package/dataflow/environments/default-builtin-config/package-data-table.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/package-data-table.js +18 -0
- package/dataflow/environments/default-builtin-config/package-spatial.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/package-spatial.js +33 -0
- package/dataflow/environments/default-builtin-config/package-tidyverse.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/package-tidyverse.js +97 -0
- package/dataflow/environments/default-builtin-config/package-utils.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/package-utils.js +38 -0
- package/dataflow/environments/default-builtin-config/package-withr.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/package-withr.js +41 -0
- package/dataflow/environments/default-builtin-config/parallel-execution.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/parallel-execution.js +33 -0
- package/dataflow/environments/default-builtin-config/r-formals.d.ts +13 -0
- package/dataflow/environments/default-builtin-config/r-formals.js +110 -0
- package/dataflow/environments/default-builtin-config/session-interactive.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/session-interactive.js +31 -0
- package/dataflow/environments/default-builtin-config/shared-configs.d.ts +328 -0
- package/dataflow/environments/default-builtin-config/shared-configs.js +447 -0
- package/dataflow/environments/default-builtin-config/shared-signatures.d.ts +21 -0
- package/dataflow/environments/default-builtin-config/shared-signatures.js +32 -0
- package/dataflow/environments/default-builtin-config/statistics.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/statistics.js +35 -0
- package/dataflow/environments/default-builtin-config/unit-testing.d.ts +3 -0
- package/dataflow/environments/default-builtin-config/unit-testing.js +13 -0
- package/dataflow/environments/diff.js +5 -2
- package/dataflow/environments/environment.d.ts +48 -52
- package/dataflow/environments/environment.js +62 -74
- package/dataflow/environments/group-generics.d.ts +16 -19
- package/dataflow/environments/group-generics.js +28 -15
- package/dataflow/environments/guard-facts.d.ts +169 -0
- package/dataflow/environments/guard-facts.js +26 -0
- package/dataflow/environments/identifier.d.ts +81 -428
- package/dataflow/environments/identifier.js +39 -145
- package/dataflow/environments/pkg-name.d.ts +198 -0
- package/dataflow/environments/pkg-name.js +3 -0
- package/dataflow/environments/query-fn-props.d.ts +28 -79
- package/dataflow/environments/query-fn-props.js +77 -115
- package/dataflow/environments/removal-marker.d.ts +2 -0
- package/dataflow/environments/removal-marker.js +5 -0
- package/dataflow/environments/resolve-by-name.d.ts +6 -16
- package/dataflow/environments/resolve-by-name.js +23 -35
- package/dataflow/environments/scoping.d.ts +5 -5
- package/dataflow/environments/scoping.js +13 -5
- package/dataflow/eval/resolve/alias-tracking.d.ts +31 -68
- package/dataflow/eval/resolve/alias-tracking.js +611 -126
- package/dataflow/eval/resolve/match-arguments.d.ts +5 -3
- package/dataflow/eval/resolve/resolve-argument.d.ts +11 -11
- package/dataflow/eval/resolve/resolve-argument.js +25 -30
- package/dataflow/eval/resolve/resolve-field.d.ts +10 -0
- package/dataflow/eval/resolve/resolve-field.js +127 -0
- package/dataflow/eval/resolve/resolve-replacement.d.ts +10 -0
- package/dataflow/eval/resolve/resolve-replacement.js +80 -0
- package/dataflow/eval/resolve/resolve-strings.d.ts +4 -7
- package/dataflow/eval/resolve/resolve-strings.js +2 -2
- package/dataflow/eval/resolve/resolve.d.ts +13 -10
- package/dataflow/eval/resolve/resolve.js +81 -32
- package/dataflow/eval/values/general.d.ts +6 -24
- package/dataflow/eval/values/general.js +12 -29
- package/dataflow/eval/values/lists/list-constants.d.ts +11 -0
- package/dataflow/eval/values/lists/list-constants.js +65 -0
- package/dataflow/eval/values/r-value.d.ts +20 -23
- package/dataflow/eval/values/r-value.js +22 -17
- package/dataflow/extractor.d.ts +2 -10
- package/dataflow/extractor.js +111 -48
- package/dataflow/fn/argument-roles.d.ts +2 -4
- package/dataflow/fn/argument-roles.js +49 -23
- package/dataflow/fn/class-declaration.d.ts +36 -52
- package/dataflow/fn/class-declaration.js +22 -56
- package/dataflow/fn/condition-handlers.d.ts +4 -1
- package/dataflow/fn/condition-handlers.js +3 -1
- package/dataflow/fn/dispatch.d.ts +70 -0
- package/dataflow/fn/dispatch.js +434 -0
- package/dataflow/fn/exceptions-of-function.d.ts +1 -2
- package/dataflow/fn/exceptions-of-function.js +36 -106
- package/dataflow/fn/frame-reflection.d.ts +5 -5
- package/dataflow/fn/frame-reflection.js +24 -16
- package/dataflow/fn/function-props.d.ts +2 -5
- package/dataflow/fn/function-props.js +30 -46
- package/dataflow/fn/function-semantics.d.ts +44 -26
- package/dataflow/fn/function-semantics.js +19 -18
- package/dataflow/fn/guards/built-in-guards.d.ts +112 -0
- package/dataflow/fn/guards/built-in-guards.js +199 -0
- package/dataflow/fn/guards/call-contracts.d.ts +97 -0
- package/dataflow/fn/guards/call-contracts.js +331 -0
- package/dataflow/fn/guards/condition-grouping.d.ts +20 -0
- package/dataflow/fn/guards/condition-grouping.js +135 -0
- package/dataflow/fn/guards/function-guards.d.ts +112 -0
- package/dataflow/fn/guards/function-guards.js +1549 -0
- package/dataflow/fn/guards/group-method-guards.d.ts +28 -0
- package/dataflow/fn/guards/group-method-guards.js +56 -0
- package/dataflow/fn/guards/guard-claims.d.ts +125 -0
- package/dataflow/fn/guards/guard-claims.js +678 -0
- package/dataflow/fn/guards/guard-knowledge.d.ts +41 -0
- package/dataflow/fn/guards/guard-knowledge.js +180 -0
- package/dataflow/fn/guards/guard-term-syntax.d.ts +9 -0
- package/dataflow/fn/guards/guard-term-syntax.js +210 -0
- package/dataflow/fn/guards/guard-term.d.ts +136 -0
- package/dataflow/fn/guards/guard-term.js +550 -0
- package/dataflow/fn/guards/stated-guards.d.ts +13 -0
- package/dataflow/fn/guards/stated-guards.js +35 -0
- package/dataflow/fn/higher-order-function.d.ts +2 -0
- package/dataflow/fn/higher-order-function.js +3 -4
- package/dataflow/fn/strict-function.d.ts +14 -35
- package/dataflow/fn/strict-function.js +183 -146
- package/dataflow/graph/ambient-access.d.ts +54 -0
- package/dataflow/graph/ambient-access.js +86 -0
- package/dataflow/graph/call-graph.d.ts +9 -29
- package/dataflow/graph/call-graph.js +17 -41
- package/dataflow/graph/closure-frames.d.ts +46 -0
- package/dataflow/graph/closure-frames.js +225 -0
- package/dataflow/graph/dataflowgraph-builder.d.ts +25 -96
- package/dataflow/graph/dataflowgraph-builder.js +29 -97
- package/dataflow/graph/df-helper.d.ts +54 -188
- package/dataflow/graph/df-helper.js +122 -208
- package/dataflow/graph/diff-dataflow-graph.d.ts +5 -15
- package/dataflow/graph/diff-dataflow-graph.js +25 -25
- package/dataflow/graph/edge.js +1 -1
- package/dataflow/graph/graph-helper.d.ts +10 -46
- package/dataflow/graph/graph-helper.js +16 -50
- package/dataflow/graph/graph.d.ts +50 -97
- package/dataflow/graph/graph.js +72 -75
- package/dataflow/graph/match-args.d.ts +21 -88
- package/dataflow/graph/match-args.js +284 -97
- package/dataflow/graph/vertex.d.ts +101 -128
- package/dataflow/graph/vertex.js +23 -20
- package/dataflow/hooks.d.ts +7 -14
- package/dataflow/hooks.js +15 -13
- package/dataflow/info.d.ts +4 -18
- package/dataflow/info.js +3 -1
- package/dataflow/internal/dispatch-linking.d.ts +73 -0
- package/dataflow/internal/dispatch-linking.js +333 -0
- package/dataflow/internal/linker.d.ts +50 -50
- package/dataflow/internal/linker.js +566 -155
- package/dataflow/internal/process/functions/call/argument/make-argument.js +2 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-access.d.ts +2 -14
- package/dataflow/internal/process/functions/call/built-in/built-in-access.js +18 -47
- package/dataflow/internal/process/functions/call/built-in/built-in-ambient-keys.d.ts +12 -8
- package/dataflow/internal/process/functions/call/built-in/built-in-ambient-keys.js +12 -10
- package/dataflow/internal/process/functions/call/built-in/built-in-ambient-state.d.ts +38 -128
- package/dataflow/internal/process/functions/call/built-in/built-in-ambient-state.js +681 -339
- package/dataflow/internal/process/functions/call/built-in/built-in-apply.d.ts +10 -7
- package/dataflow/internal/process/functions/call/built-in/built-in-apply.js +78 -45
- package/dataflow/internal/process/functions/call/built-in/built-in-assignment.d.ts +17 -19
- package/dataflow/internal/process/functions/call/built-in/built-in-assignment.js +185 -78
- package/dataflow/internal/process/functions/call/built-in/built-in-attach.d.ts +5 -5
- package/dataflow/internal/process/functions/call/built-in/built-in-attach.js +26 -5
- package/dataflow/internal/process/functions/call/built-in/built-in-class-generator.d.ts +2 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-class-generator.js +3 -2
- package/dataflow/internal/process/functions/call/built-in/built-in-deferred-env-ops.d.ts +15 -0
- package/dataflow/internal/process/functions/call/built-in/built-in-deferred-env-ops.js +438 -0
- package/dataflow/internal/process/functions/call/built-in/built-in-env-contents.js +4 -0
- package/dataflow/internal/process/functions/call/built-in/built-in-envir-utils.d.ts +40 -57
- package/dataflow/internal/process/functions/call/built-in/built-in-envir-utils.js +214 -117
- package/dataflow/internal/process/functions/call/built-in/built-in-eval.d.ts +4 -3
- package/dataflow/internal/process/functions/call/built-in/built-in-eval.js +74 -17
- package/dataflow/internal/process/functions/call/built-in/built-in-expression-list.d.ts +20 -5
- package/dataflow/internal/process/functions/call/built-in/built-in-expression-list.js +420 -115
- package/dataflow/internal/process/functions/call/built-in/built-in-for-loop.d.ts +1 -7
- package/dataflow/internal/process/functions/call/built-in/built-in-for-loop.js +6 -14
- package/dataflow/internal/process/functions/call/built-in/built-in-function-definition.d.ts +8 -7
- package/dataflow/internal/process/functions/call/built-in/built-in-function-definition.js +530 -140
- package/dataflow/internal/process/functions/call/built-in/built-in-get.d.ts +20 -10
- package/dataflow/internal/process/functions/call/built-in/built-in-get.js +98 -13
- package/dataflow/internal/process/functions/call/built-in/built-in-if-then-else.d.ts +2 -6
- package/dataflow/internal/process/functions/call/built-in/built-in-if-then-else.js +9 -16
- package/dataflow/internal/process/functions/call/built-in/built-in-library.d.ts +14 -8
- package/dataflow/internal/process/functions/call/built-in/built-in-library.js +40 -7
- package/dataflow/internal/process/functions/call/built-in/built-in-load.js +18 -8
- package/dataflow/internal/process/functions/call/built-in/built-in-local.d.ts +8 -5
- package/dataflow/internal/process/functions/call/built-in/built-in-local.js +39 -8
- package/dataflow/internal/process/functions/call/built-in/built-in-purrr-formula.d.ts +9 -24
- package/dataflow/internal/process/functions/call/built-in/built-in-purrr-formula.js +10 -6
- package/dataflow/internal/process/functions/call/built-in/built-in-recall.js +4 -0
- package/dataflow/internal/process/functions/call/built-in/built-in-register-hook.d.ts +5 -6
- package/dataflow/internal/process/functions/call/built-in/built-in-register-hook.js +3 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-replacement.d.ts +1 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-replacement.js +27 -12
- package/dataflow/internal/process/functions/call/built-in/built-in-rm.d.ts +2 -6
- package/dataflow/internal/process/functions/call/built-in/built-in-rm.js +74 -38
- package/dataflow/internal/process/functions/call/built-in/built-in-s-four.d.ts +17 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-s-four.js +117 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-s-seven-new-generic.d.ts +5 -3
- package/dataflow/internal/process/functions/call/built-in/built-in-s-seven-new-generic.js +3 -3
- package/dataflow/internal/process/functions/call/built-in/built-in-s-three-dispatch.d.ts +8 -4
- package/dataflow/internal/process/functions/call/built-in/built-in-s-three-dispatch.js +18 -29
- package/dataflow/internal/process/functions/call/built-in/built-in-source.d.ts +9 -27
- package/dataflow/internal/process/functions/call/built-in/built-in-source.js +42 -45
- package/dataflow/internal/process/functions/call/built-in/built-in-special-bin-op.js +3 -1
- package/dataflow/internal/process/functions/call/built-in/built-in-stack-env.d.ts +12 -18
- package/dataflow/internal/process/functions/call/built-in/built-in-stack-env.js +72 -21
- package/dataflow/internal/process/functions/call/built-in/built-in-try-catch.d.ts +19 -17
- package/dataflow/internal/process/functions/call/built-in/built-in-try-catch.js +286 -81
- package/dataflow/internal/process/functions/call/built-in/built-in-while-loop.js +7 -4
- package/dataflow/internal/process/functions/call/built-in/transitive-side-effects.d.ts +44 -30
- package/dataflow/internal/process/functions/call/built-in/transitive-side-effects.js +723 -115
- package/dataflow/internal/process/functions/call/common.d.ts +8 -24
- package/dataflow/internal/process/functions/call/common.js +24 -24
- package/dataflow/internal/process/functions/call/deferred.d.ts +7 -27
- package/dataflow/internal/process/functions/call/deferred.js +6 -27
- package/dataflow/internal/process/functions/call/known-call-handling.d.ts +6 -26
- package/dataflow/internal/process/functions/call/known-call-handling.js +6 -16
- package/dataflow/internal/process/functions/call/named-call-handling.d.ts +1 -4
- package/dataflow/internal/process/functions/call/named-call-handling.js +14 -35
- package/dataflow/internal/process/functions/call/nse.d.ts +2 -9
- package/dataflow/internal/process/functions/call/nse.js +6 -13
- package/dataflow/internal/process/functions/call/quoted.d.ts +6 -15
- package/dataflow/internal/process/functions/call/quoted.js +48 -65
- package/dataflow/internal/process/functions/call/unnamed-call-handling.d.ts +3 -6
- package/dataflow/internal/process/functions/call/unnamed-call-handling.js +29 -11
- package/dataflow/internal/process/functions/process-parameter.js +1 -1
- package/dataflow/internal/program-order.d.ts +3 -10
- package/dataflow/internal/program-order.js +19 -10
- package/dataflow/origin/dfg-get-origin.js +2 -1
- package/dataflow/processor.d.ts +2 -0
- package/documentation/data/dfg/doc-ambient.d.ts +4 -0
- package/documentation/data/dfg/doc-ambient.js +74 -0
- package/documentation/data/faq/faqs.js +16 -1
- package/documentation/data/interface/doc-writing-code.js +5 -7
- package/documentation/doc-capabilities.js +3 -3
- package/documentation/doc-readme.js +1 -1
- package/documentation/doc-util/doc-code.d.ts +0 -5
- package/documentation/doc-util/doc-code.js +2 -22
- package/documentation/doc-util/doc-query.d.ts +1 -2
- package/documentation/doc-util/doc-query.js +4 -5
- package/documentation/doc-util/doc-search.js +1 -1
- package/documentation/wiki-analyzer.js +4 -3
- package/documentation/wiki-core.js +5 -5
- package/documentation/wiki-dataflow-graph.js +15 -3
- package/documentation/wiki-interface.js +2 -1
- package/documentation/wiki-linter.js +27 -3
- package/documentation/wiki-linting-and-testing.js +15 -2
- package/documentation/wiki-query.js +223 -30
- package/index.d.ts +3 -1
- package/index.js +6 -3
- package/linter/linter-executor.js +1 -1
- package/linter/linter-rules.d.ts +78 -9
- package/linter/linter-rules.js +12 -1
- package/linter/linter-util.d.ts +3 -3
- package/linter/linter-util.js +1 -1
- package/linter/rules/call-contracts.d.ts +40 -0
- package/linter/rules/call-contracts.js +56 -0
- package/linter/rules/cmd-check/bogus-return.d.ts +2 -1
- package/linter/rules/cmd-check/bogus-return.js +1 -1
- package/linter/rules/cmd-check/call-arguments.d.ts +3 -2
- package/linter/rules/cmd-check/call-arguments.js +10 -11
- package/linter/rules/cmd-check/cmd-check-util.d.ts +8 -13
- package/linter/rules/cmd-check/cmd-check-util.js +0 -28
- package/linter/rules/cmd-check/dependency-declaration.d.ts +2 -1
- package/linter/rules/cmd-check/dependency-declaration.js +1 -1
- package/linter/rules/cmd-check/documentation-mismatch.d.ts +3 -2
- package/linter/rules/cmd-check/documentation-mismatch.js +2 -1
- package/linter/rules/cmd-check/file-checks.d.ts +2 -2
- package/linter/rules/cmd-check/foreign-function-calls.d.ts +2 -1
- package/linter/rules/cmd-check/global-environment-modification.d.ts +6 -5
- package/linter/rules/cmd-check/namespace-tampering.d.ts +2 -1
- package/linter/rules/cmd-check/non-ascii-code.js +1 -1
- package/linter/rules/cmd-check/package-files.d.ts +2 -2
- package/linter/rules/cmd-check/package-hooks.d.ts +5 -4
- package/linter/rules/cmd-check/package-hooks.js +2 -1
- package/linter/rules/cmd-check/package-runtime.js +2 -2
- package/linter/rules/cmd-check/rd-files.js +2 -1
- package/linter/rules/cmd-check/s-three-method-consistency.d.ts +3 -2
- package/linter/rules/cmd-check/s-three-method-consistency.js +3 -2
- package/linter/rules/code-clones.d.ts +57 -0
- package/linter/rules/code-clones.js +53 -0
- package/linter/rules/deprecated-functions.js +3 -6
- package/linter/rules/file-path-validity.js +6 -4
- package/linter/rules/function-finder-util.d.ts +4 -2
- package/linter/rules/interactive-functions.d.ts +30 -0
- package/linter/rules/interactive-functions.js +87 -0
- package/linter/rules/naming-convention.d.ts +6 -5
- package/linter/rules/naming-convention.js +2 -3
- package/linter/rules/no-leaked-credentials.d.ts +2 -1
- package/linter/rules/no-leaked-credentials.js +1 -1
- package/linter/rules/overwritten-file.d.ts +2 -1
- package/linter/rules/problematic-inputs.d.ts +2 -1
- package/linter/rules/problematic-inputs.js +3 -3
- package/linter/rules/process-state-in-session.d.ts +7 -6
- package/linter/rules/process-state-in-session.js +2 -2
- package/linter/rules/roxygen-arguments.d.ts +1 -1
- package/linter/rules/secret-exfiltration.js +1 -1
- package/linter/rules/seeded-randomness.d.ts +3 -3
- package/linter/rules/unclosed-connection.js +1 -2
- package/linter/rules/undefined-symbol-util.d.ts +4 -3
- package/linter/rules/undefined-symbol-util.js +8 -2
- package/linter/rules/undefined-symbol.d.ts +3 -2
- package/linter/rules/undefined-symbol.js +18 -7
- package/linter/rules/unescaped-arguments.d.ts +1 -1
- package/linter/rules/unescaped-arguments.js +6 -8
- package/linter/rules/unused-definition.d.ts +4 -3
- package/linter/rules/unused-definition.js +10 -12
- package/linter/rules/unused-import.d.ts +6 -5
- package/linter/rules/useless-loop.d.ts +1 -1
- package/package.json +1 -1
- package/project/attached-packages.d.ts +5 -4
- package/project/cache/flowr-analyzer-cache.d.ts +14 -1
- package/project/cache/flowr-analyzer-cache.js +40 -3
- package/project/context/flowr-analyzer-dependencies-context.d.ts +12 -12
- package/project/context/flowr-analyzer-dependencies-context.js +2 -1
- package/project/context/flowr-analyzer-environment-context.d.ts +3 -3
- package/project/context/flowr-analyzer-environment-context.js +3 -3
- package/project/context/flowr-analyzer-functions-context.d.ts +9 -7
- package/project/context/flowr-analyzer-gas-context.d.ts +25 -0
- package/project/context/flowr-analyzer-gas-context.js +34 -4
- package/project/dependency-version-space.d.ts +30 -29
- package/project/dependency-version-space.js +1 -2
- package/project/flowr-analyzer-builder.d.ts +2 -3
- package/project/flowr-analyzer.d.ts +36 -3
- package/project/flowr-analyzer.js +8 -2
- package/project/plugins/file-plugins/files/flowr-namespace-file.d.ts +15 -14
- package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-on-demand-plugin.d.ts +5 -4
- package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-on-demand-plugin.js +1 -1
- package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-plugin.d.ts +2 -1
- package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-sigdb-plugin.d.ts +4 -3
- package/project/plugins/package-version-plugins/flowr-analyzer-package-versions-sigdb-plugin.js +2 -1
- package/project/plugins/package-version-plugins/package.d.ts +6 -5
- package/project/sigdb/build.js +15 -5
- package/project/sigdb/decode.d.ts +11 -7
- package/project/sigdb/decode.js +11 -3
- package/project/sigdb/dict.d.ts +2 -1
- package/project/sigdb/dict.js +2 -2
- package/project/sigdb/guarded-source.d.ts +6 -0
- package/project/sigdb/guarded-source.js +29 -0
- package/project/sigdb/index-format.d.ts +2 -1
- package/project/sigdb/manifest.d.ts +1 -1
- package/project/sigdb/memory-source.d.ts +18 -17
- package/project/sigdb/on-demand/package-sources.d.ts +4 -3
- package/project/sigdb/on-demand/recoverer.d.ts +2 -1
- package/project/sigdb/on-demand/remote-sources.d.ts +2 -1
- package/project/sigdb/reader.d.ts +90 -80
- package/project/sigdb/reader.js +27 -5
- package/project/sigdb/schema.d.ts +33 -10
- package/project/sigdb/signature-db.d.ts +6 -6
- package/queries/catalog/absint-query/absint-query-format.d.ts +6 -3
- package/queries/catalog/absint-query/absint-query-format.js +57 -2
- package/queries/catalog/ambient-access-query/ambient-access-query-format.d.ts +58 -0
- package/queries/catalog/ambient-access-query/ambient-access-query-format.js +90 -0
- package/queries/catalog/call-context-query/call-context-query-executor.d.ts +2 -1
- package/queries/catalog/call-context-query/call-context-query-executor.js +2 -2
- package/queries/catalog/call-graph-query/expand-library-internals.d.ts +3 -2
- package/queries/catalog/cluster-query/cluster-query-format.d.ts +5 -2
- package/queries/catalog/cluster-query/cluster-query-format.js +19 -2
- package/queries/catalog/code-clones-query/code-clones-query-format.d.ts +57 -0
- package/queries/catalog/code-clones-query/code-clones-query-format.js +105 -0
- package/queries/catalog/config-query/config-query-format.d.ts +5 -2
- package/queries/catalog/config-query/config-query-format.js +41 -2
- package/queries/catalog/control-flow-query/control-flow-query-format.d.ts +5 -2
- package/queries/catalog/control-flow-query/control-flow-query-format.js +19 -2
- package/queries/catalog/data-columns-query/data-columns-query-format.d.ts +72 -0
- package/queries/catalog/data-columns-query/data-columns-query-format.js +215 -0
- package/queries/catalog/dataflow-lens-query/dataflow-lens-query-format.d.ts +5 -2
- package/queries/catalog/dataflow-lens-query/dataflow-lens-query-format.js +38 -2
- package/queries/catalog/dataflow-query/dataflow-query-format.d.ts +5 -2
- package/queries/catalog/dataflow-query/dataflow-query-format.js +18 -2
- package/queries/catalog/dependencies-query/data-flow.d.ts +5 -4
- package/queries/catalog/dependencies-query/dependencies-query-executor.d.ts +5 -2
- package/queries/catalog/dependencies-query/dependencies-query-executor.js +5 -5
- package/queries/catalog/dependencies-query/dependencies-query-format.d.ts +4 -3
- package/queries/catalog/dependencies-query/dependencies-query-format.js +9 -4
- package/queries/catalog/dependencies-query/function-info/function-info.d.ts +6 -4
- package/queries/catalog/dependencies-query/function-info/other-path-functions.js +1 -1
- package/queries/catalog/dependencies-query/function-info/tagged-functions.d.ts +11 -0
- package/queries/catalog/dependencies-query/function-info/tagged-functions.js +18 -0
- package/queries/catalog/dependencies-query/implicit-echo.js +2 -1
- package/queries/catalog/dice-query/dice-query-format.d.ts +8 -2
- package/queries/catalog/dice-query/dice-query-format.js +35 -2
- package/queries/catalog/does-call-query/does-call-query-format.d.ts +8 -4
- package/queries/catalog/does-call-query/does-call-query-format.js +115 -2
- package/queries/catalog/files-query/files-query-format.d.ts +5 -2
- package/queries/catalog/files-query/files-query-format.js +45 -2
- package/queries/catalog/function-info-query/function-info-query-format.d.ts +2 -1
- package/queries/catalog/function-info-query/function-origin.d.ts +3 -2
- package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-format.d.ts +11 -7
- package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-format.js +303 -2
- package/queries/catalog/happens-before-query/happens-before-query-format.d.ts +9 -4
- package/queries/catalog/happens-before-query/happens-before-query-format.js +38 -2
- package/queries/catalog/id-map-query/id-map-query-format.d.ts +5 -2
- package/queries/catalog/id-map-query/id-map-query-format.js +18 -2
- package/queries/catalog/input-sources-query/input-sources-query-executor.js +7 -3
- package/queries/catalog/input-sources-query/simple-input-classifier.d.ts +9 -9
- package/queries/catalog/input-sources-query/simple-input-classifier.js +1 -1
- package/queries/catalog/inspect-exceptions-query/inspect-exception-query-format.d.ts +5 -2
- package/queries/catalog/inspect-exceptions-query/inspect-exception-query-format.js +29 -2
- package/queries/catalog/inspect-fn-guards-query/inspect-fn-guards-query-format.d.ts +37 -0
- package/queries/catalog/inspect-fn-guards-query/inspect-fn-guards-query-format.js +125 -0
- package/queries/catalog/inspect-fn-props-query/inspect-fn-props-query-format.d.ts +3 -2
- package/queries/catalog/inspect-fn-props-query/inspect-fn-props-query-format.js +54 -2
- package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-format.d.ts +6 -2
- package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-format.js +23 -2
- package/queries/catalog/inspect-recursion-query/inspect-recursion-query-format.d.ts +6 -2
- package/queries/catalog/inspect-recursion-query/inspect-recursion-query-format.js +15 -2
- package/queries/catalog/linter-query/linter-query-format.d.ts +8 -2
- package/queries/catalog/linter-query/linter-query-format.js +72 -6
- package/queries/catalog/location-map-query/location-map-query-format.d.ts +7 -3
- package/queries/catalog/location-map-query/location-map-query-format.js +70 -2
- package/queries/catalog/normalized-ast-query/normalized-ast-query-format.d.ts +5 -2
- package/queries/catalog/normalized-ast-query/normalized-ast-query-format.js +18 -2
- package/queries/catalog/origin-query/origin-query-format.d.ts +7 -3
- package/queries/catalog/origin-query/origin-query-format.js +30 -2
- package/queries/catalog/project-query/project-query-format.d.ts +8 -4
- package/queries/catalog/project-query/project-query-format.js +98 -2
- package/queries/catalog/provenance-query/provenance-query-format.d.ts +7 -3
- package/queries/catalog/provenance-query/provenance-query-format.js +31 -2
- package/queries/catalog/resolve-value-query/resolve-value-query-format.d.ts +10 -2
- package/queries/catalog/resolve-value-query/resolve-value-query-format.js +39 -2
- package/queries/catalog/search-query/search-query-format.d.ts +5 -2
- package/queries/catalog/search-query/search-query-format.js +23 -2
- package/queries/catalog/signature-query/signature-query-executor.d.ts +9 -6
- package/queries/catalog/signature-query/signature-query-executor.js +17 -16
- package/queries/catalog/signature-query/signature-query-format.d.ts +24 -20
- package/queries/catalog/signature-query/signature-query-render.js +24 -1
- package/queries/catalog/static-slice-query/static-slice-query-format.d.ts +22 -7
- package/queries/catalog/static-slice-query/static-slice-query-format.js +56 -2
- package/queries/catalog/taint-query/taint-query-format.d.ts +6 -3
- package/queries/catalog/taint-query/taint-query-format.js +28 -2
- package/queries/query-function-filter.d.ts +1 -1
- package/queries/query.d.ts +104 -32
- package/queries/query.js +61 -37
- package/r-bridge/data/data.d.ts +39 -28
- package/r-bridge/data/data.js +37 -28
- package/r-bridge/lang-4.x/ast/model/model.d.ts +10 -1
- package/r-bridge/lang-4.x/ast/model/model.js +30 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-access.d.ts +21 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-access.js +25 -2
- package/r-bridge/lang-4.x/ast/model/nodes/r-argument.d.ts +2 -1
- package/r-bridge/lang-4.x/ast/model/nodes/r-binary-op.d.ts +3 -2
- package/r-bridge/lang-4.x/ast/model/nodes/r-binary-op.js +2 -2
- 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-comment.d.ts +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-for-loop.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-function-call.d.ts +4 -3
- 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-if-then-else.d.ts +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-logical.d.ts +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-number.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-parameter.d.ts +1 -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-repeat-loop.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/nodes/r-string.d.ts +5 -6
- package/r-bridge/lang-4.x/ast/model/nodes/r-string.js +2 -7
- 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-unary-op.d.ts +3 -2
- package/r-bridge/lang-4.x/ast/model/nodes/r-unary-op.js +2 -2
- package/r-bridge/lang-4.x/ast/model/nodes/r-while-loop.d.ts +1 -0
- package/r-bridge/lang-4.x/ast/model/processing/decorate.js +4 -5
- package/r-bridge/lang-4.x/ast/model/processing/node-id.d.ts +9 -2
- package/r-bridge/lang-4.x/ast/model/processing/node-id.js +18 -6
- package/r-bridge/lang-4.x/ast/model/processing/visitor.d.ts +1 -1
- package/r-bridge/lang-4.x/ast/model/processing/visitor.js +2 -2
- package/r-bridge/lang-4.x/ast/model/type.d.ts +1 -1
- package/r-bridge/lang-4.x/ast/model/type.js +1 -1
- package/r-bridge/lang-4.x/ast/parser/main/internal/operators/normalize-binary.js +2 -2
- package/r-bridge/lang-4.x/ast/parser/main/internal/operators/normalize-unary.js +2 -2
- package/r-bridge/lang-4.x/tree-sitter/tree-sitter-executor.d.ts +2 -2
- package/r-bridge/lang-4.x/tree-sitter/tree-sitter-executor.js +3 -2
- package/r-bridge/parser.d.ts +8 -2
- package/r-bridge/parser.js +6 -0
- package/r-bridge/shell-executor.d.ts +2 -2
- package/r-bridge/shell-executor.js +3 -2
- package/r-bridge/shell.d.ts +2 -2
- package/r-bridge/shell.js +10 -4
- package/reconstruct/auto-select/magic-comments.js +1 -1
- package/reconstruct/reconstruct.d.ts +0 -5
- package/reconstruct/reconstruct.js +24 -8
- package/search/flowr-search-builder.d.ts +14 -0
- package/search/flowr-search-builder.js +7 -0
- package/search/flowr-search-executor.js +2 -2
- package/search/flowr-search-filters.js +8 -9
- package/search/flowr-search.js +1 -1
- package/search/search-executor/search-enrichers.d.ts +2 -0
- package/search/search-executor/search-enrichers.js +6 -1
- package/search/search-executor/search-generators.d.ts +2 -2
- package/search/search-executor/search-generators.js +13 -8
- package/search/search-executor/search-mappers.js +1 -1
- package/search/search-executor/search-transformer.d.ts +2 -2
- package/search/search-executor/search-transformer.js +6 -6
- package/slicing/criterion/parse.d.ts +2 -1
- package/slicing/criterion/parse.js +2 -1
- package/slicing/static/removal-slice.js +6 -4
- package/slicing/static/slice-call.d.ts +41 -4
- package/slicing/static/slice-call.js +117 -11
- package/slicing/static/slicer-types.d.ts +2 -1
- package/slicing/static/static-slicer.d.ts +2 -0
- package/slicing/static/static-slicer.js +199 -28
- package/slicing/static/visiting-queue.d.ts +4 -0
- package/slicing/static/visiting-queue.js +8 -0
- package/taint-analysis/builder/report-template.d.ts +3 -3
- package/util/arg-matching.d.ts +1 -1
- package/util/collections/relation.d.ts +23 -0
- package/util/collections/relation.js +63 -0
- package/util/fixpoint.d.ts +65 -0
- package/util/fixpoint.js +216 -0
- package/util/flowr-version.d.ts +1 -1
- package/util/flowr-version.js +2 -2
- package/util/json.d.ts +4 -0
- package/util/json.js +12 -3
- package/util/mermaid/cfg.js +1 -2
- package/util/mermaid/dfg.d.ts +1 -1
- package/util/mermaid/dfg.js +1 -1
- package/util/mermaid/mermaid.d.ts +2 -1
- package/util/monoid.d.ts +26 -0
- package/util/monoid.js +31 -0
- package/util/objects.d.ts +2 -0
- package/util/objects.js +5 -0
- package/util/prefix.d.ts +1 -1
- package/util/r-base-packages.d.ts +10 -7
- package/util/r-base-packages.js +11 -6
- package/util/r-datasets.d.ts +27 -0
- package/util/r-datasets.js +45 -0
- package/util/r-package-urls.d.ts +10 -9
- package/util/r-value.js +2 -1
- package/util/r-version-order.d.ts +2 -0
- package/util/r-version-order.js +19 -0
- package/util/r-version.d.ts +2 -1
- package/util/r-version.js +2 -14
- package/util/range.d.ts +38 -29
- package/util/range.js +10 -5
- package/util/simple-df/dfg-ascii.js +2 -2
- package/util/text/ansi.d.ts +13 -9
- package/util/text/ansi.js +4 -6
- package/util/text/playground-link.d.ts +2 -0
- package/util/text/playground-link.js +2 -0
- package/util/text/strings.d.ts +10 -3
- package/util/text/strings.js +10 -1
- package/util/version.d.ts +1 -1
- package/util/version.js +2 -1
- package/dataflow/environments/default-builtin-config.d.ts +0 -8874
- package/dataflow/environments/default-builtin-config.js +0 -1737
- package/queries/catalog/absint-query/absint-query-executor.d.ts +0 -6
- package/queries/catalog/absint-query/absint-query-executor.js +0 -61
- package/queries/catalog/cluster-query/cluster-query-executor.d.ts +0 -6
- package/queries/catalog/cluster-query/cluster-query-executor.js +0 -21
- package/queries/catalog/config-query/config-query-executor.d.ts +0 -6
- package/queries/catalog/config-query/config-query-executor.js +0 -45
- package/queries/catalog/control-flow-query/control-flow-query-executor.d.ts +0 -6
- package/queries/catalog/control-flow-query/control-flow-query-executor.js +0 -21
- package/queries/catalog/dataflow-lens-query/dataflow-lens-query-executor.d.ts +0 -6
- package/queries/catalog/dataflow-lens-query/dataflow-lens-query-executor.js +0 -40
- package/queries/catalog/dataflow-query/dataflow-query-executor.d.ts +0 -6
- package/queries/catalog/dataflow-query/dataflow-query-executor.js +0 -20
- package/queries/catalog/dependencies-query/function-info/statistics-functions.d.ts +0 -9
- package/queries/catalog/dependencies-query/function-info/statistics-functions.js +0 -18
- package/queries/catalog/dice-query/dice-query-executor.d.ts +0 -8
- package/queries/catalog/dice-query/dice-query-executor.js +0 -37
- package/queries/catalog/does-call-query/does-call-query-executor.d.ts +0 -6
- package/queries/catalog/does-call-query/does-call-query-executor.js +0 -117
- package/queries/catalog/files-query/files-query-executor.d.ts +0 -6
- package/queries/catalog/files-query/files-query-executor.js +0 -47
- package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-executor.d.ts +0 -6
- package/queries/catalog/guess-dep-versions-query/guess-dep-versions-query-executor.js +0 -307
- package/queries/catalog/happens-before-query/happens-before-query-executor.d.ts +0 -7
- package/queries/catalog/happens-before-query/happens-before-query-executor.js +0 -40
- package/queries/catalog/id-map-query/id-map-query-executor.d.ts +0 -6
- package/queries/catalog/id-map-query/id-map-query-executor.js +0 -20
- package/queries/catalog/inspect-exceptions-query/inspect-exception-query-executor.d.ts +0 -6
- package/queries/catalog/inspect-exceptions-query/inspect-exception-query-executor.js +0 -31
- package/queries/catalog/inspect-fn-props-query/inspect-fn-props-query-executor.d.ts +0 -4
- package/queries/catalog/inspect-fn-props-query/inspect-fn-props-query-executor.js +0 -58
- package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-executor.d.ts +0 -7
- package/queries/catalog/inspect-higher-order-query/inspect-higher-order-query-executor.js +0 -25
- package/queries/catalog/inspect-recursion-query/inspect-recursion-query-executor.d.ts +0 -7
- package/queries/catalog/inspect-recursion-query/inspect-recursion-query-executor.js +0 -17
- package/queries/catalog/linter-query/linter-query-executor.d.ts +0 -9
- package/queries/catalog/linter-query/linter-query-executor.js +0 -59
- package/queries/catalog/location-map-query/location-map-query-executor.d.ts +0 -7
- package/queries/catalog/location-map-query/location-map-query-executor.js +0 -73
- package/queries/catalog/normalized-ast-query/normalized-ast-query-executor.d.ts +0 -6
- package/queries/catalog/normalized-ast-query/normalized-ast-query-executor.js +0 -20
- package/queries/catalog/origin-query/origin-query-executor.d.ts +0 -6
- package/queries/catalog/origin-query/origin-query-executor.js +0 -31
- package/queries/catalog/project-query/project-query-executor.d.ts +0 -6
- package/queries/catalog/project-query/project-query-executor.js +0 -103
- package/queries/catalog/provenance-query/provenance-query-executor.d.ts +0 -6
- package/queries/catalog/provenance-query/provenance-query-executor.js +0 -33
- package/queries/catalog/resolve-value-query/resolve-value-query-executor.d.ts +0 -10
- package/queries/catalog/resolve-value-query/resolve-value-query-executor.js +0 -40
- package/queries/catalog/search-query/search-query-executor.d.ts +0 -6
- package/queries/catalog/search-query/search-query-executor.js +0 -25
- package/queries/catalog/static-slice-query/static-slice-query-executor.d.ts +0 -14
- package/queries/catalog/static-slice-query/static-slice-query-executor.js +0 -59
- package/queries/catalog/taint-query/taint-query-executor.d.ts +0 -7
- package/queries/catalog/taint-query/taint-query-executor.js +0 -30
- package/r-bridge/lang-4.x/ast/model/operators.d.ts +0 -33
- package/r-bridge/lang-4.x/ast/model/operators.js +0 -54
- package/taint-analysis/eval/eval.js +0 -124
- package/taint-analysis/eval/instrumentation.d.ts +0 -59
- package/taint-analysis/eval/instrumentation.js +0 -124
- /package/{taint-analysis/eval/eval.d.ts → abstract-interpretation/branch-paths-interpreter.d.ts} +0 -0
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import type { BaseQueryFormat, BaseQueryResult, BasicQueryData } from '../../base-query-format';
|
|
2
|
+
import type { OutputFormatter } from '../../../util/text/ansi';
|
|
3
|
+
import Joi from 'joi';
|
|
4
|
+
import type { NodeId } from '../../../r-bridge/lang-4.x/ast/model/processing/node-id';
|
|
5
|
+
import type { ReplOutput } from '../../../cli/repl/commands/repl-main';
|
|
6
|
+
import type { FlowrConfig } from '../../../config';
|
|
7
|
+
import type { ParsedQueryLine } from '../../query';
|
|
8
|
+
import { criteriaQueryCompleter } from '../../../cli/repl/parser/slice-query-parser';
|
|
9
|
+
/**
|
|
10
|
+
* Executes data columns queries: the data frame shape inference runs once for all of them.
|
|
11
|
+
*/
|
|
12
|
+
export declare function executeDataColumnsQuery({ analyzer }: BasicQueryData, queries: readonly DataColumnsQuery[]): Promise<DataColumnsQueryResult>;
|
|
13
|
+
/**
|
|
14
|
+
* Asks which columns of a data frame can be written at a position of the code, as an editor offers them to complete:
|
|
15
|
+
* after `df$` or `df[["`, and in every argument a call evaluates within its data, as `filter(penguins, bi)`,
|
|
16
|
+
* `penguins |> mutate(r = bi)`, `subset(mtcars, mpg > 20)`, `with(iris, ...)`, or `ggplot(penguins, aes(x = bi))`.
|
|
17
|
+
*/
|
|
18
|
+
export interface DataColumnsQuery extends BaseQueryFormat {
|
|
19
|
+
readonly type: 'data-columns';
|
|
20
|
+
/**
|
|
21
|
+
* The positions to ask about, as `line:column` (both starting at 1) of the cursor, which may stand just past the
|
|
22
|
+
* name typed so far. The position has to fall within a node: an editor completing nothing typed yet inserts a
|
|
23
|
+
* placeholder name there first, as `filter(penguins, )` is no different from `filter(penguins)`.
|
|
24
|
+
*/
|
|
25
|
+
readonly positions: readonly string[];
|
|
26
|
+
/** The file the positions are in, as flowR names it, if the analysis holds more than one. */
|
|
27
|
+
readonly file?: string;
|
|
28
|
+
}
|
|
29
|
+
/** How the columns can be written at the position. */
|
|
30
|
+
export declare enum DataColumnsContext {
|
|
31
|
+
/** as the name accessed of a data frame, `df$col` or `df[["col"]]` */
|
|
32
|
+
Access = "access",
|
|
33
|
+
/** as a name a call evaluates within its data, `filter(df, col > 1)` */
|
|
34
|
+
Masked = "masked"
|
|
35
|
+
}
|
|
36
|
+
/** One data frame whose columns can be written at a position. */
|
|
37
|
+
export interface DataColumnsFrame {
|
|
38
|
+
/** the node of the data frame, e.g. the `penguins` of `filter(penguins, ...)` */
|
|
39
|
+
readonly id: NodeId;
|
|
40
|
+
/** the code of the node, if it has any of its own */
|
|
41
|
+
readonly lexeme?: string;
|
|
42
|
+
/** the columns it surely has */
|
|
43
|
+
readonly must: readonly string[];
|
|
44
|
+
/** the columns it may have as well */
|
|
45
|
+
readonly may: readonly string[];
|
|
46
|
+
/** whether it has no other columns than these */
|
|
47
|
+
readonly exact: boolean;
|
|
48
|
+
}
|
|
49
|
+
/** The columns that can be written at one position. */
|
|
50
|
+
export interface DataColumnsAt {
|
|
51
|
+
/** how the columns are written there, absent where no data frame is in reach */
|
|
52
|
+
readonly context?: DataColumnsContext;
|
|
53
|
+
/** every column of the {@link frames}, those they surely have first */
|
|
54
|
+
readonly columns: readonly string[];
|
|
55
|
+
readonly frames: readonly DataColumnsFrame[];
|
|
56
|
+
}
|
|
57
|
+
export interface DataColumnsQueryResult extends BaseQueryResult {
|
|
58
|
+
/** the columns at each position asked about, by the position as given */
|
|
59
|
+
readonly results: Record<string, DataColumnsAt>;
|
|
60
|
+
}
|
|
61
|
+
declare function dataColumnsLineParser(_output: ReplOutput, line: readonly string[], _config: FlowrConfig): ParsedQueryLine<'data-columns'>;
|
|
62
|
+
export declare const DataColumnsQueryDefinition: {
|
|
63
|
+
readonly title: "Data Columns Query";
|
|
64
|
+
readonly executor: typeof executeDataColumnsQuery;
|
|
65
|
+
readonly asciiSummarizer: (formatter: OutputFormatter, _analyzer: unknown, queryResults: BaseQueryResult, result: string[]) => true;
|
|
66
|
+
readonly fromLine: typeof dataColumnsLineParser;
|
|
67
|
+
readonly completer: typeof criteriaQueryCompleter;
|
|
68
|
+
readonly syntax: "@data-columns (<line:col>;...) <code | file://path>";
|
|
69
|
+
readonly schema: Joi.ObjectSchema<any>;
|
|
70
|
+
readonly flattenInvolvedNodes: (queryResults: BaseQueryResult) => NodeId[];
|
|
71
|
+
};
|
|
72
|
+
export {};
|
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.DataColumnsQueryDefinition = exports.DataColumnsContext = void 0;
|
|
7
|
+
exports.executeDataColumnsQuery = executeDataColumnsQuery;
|
|
8
|
+
const ansi_1 = require("../../../util/text/ansi");
|
|
9
|
+
const joi_1 = __importDefault(require("joi"));
|
|
10
|
+
const query_print_1 = require("../../query-print");
|
|
11
|
+
const slice_query_parser_1 = require("../../../cli/repl/parser/slice-query-parser");
|
|
12
|
+
const absint_inference_1 = require("../../../abstract-interpretation/absint-inference");
|
|
13
|
+
const shape_inference_1 = require("../../../abstract-interpretation/data-frame/shape-inference");
|
|
14
|
+
const model_1 = require("../../../r-bridge/lang-4.x/ast/model/model");
|
|
15
|
+
const r_access_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-access");
|
|
16
|
+
const r_argument_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-argument");
|
|
17
|
+
const r_binary_op_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-binary-op");
|
|
18
|
+
const r_function_call_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-function-call");
|
|
19
|
+
const r_pipe_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-pipe");
|
|
20
|
+
const identifier_1 = require("../../../dataflow/environments/identifier");
|
|
21
|
+
const arrays_1 = require("../../../util/collections/arrays");
|
|
22
|
+
const query_meta_1 = require("../../query-meta");
|
|
23
|
+
/** the pipes that hand their left side to the call on their right as its data */
|
|
24
|
+
const Pipes = new Set(['|>', '%>%', '%<>%', '%T>%', '%$%']);
|
|
25
|
+
/** the operators binding a value to a name, whose sides are no data of the call that is evaluated within */
|
|
26
|
+
const Assignments = new Set(['<-', '=', '<<-', '->', '->>', ':=']);
|
|
27
|
+
/** the innermost node whose code holds `line`:`col`, where a cursor just past a name still counts as within it */
|
|
28
|
+
function innermostAt(idMap, line, col, file) {
|
|
29
|
+
let best;
|
|
30
|
+
let size = Infinity;
|
|
31
|
+
for (const node of idMap.values()) {
|
|
32
|
+
const range = model_1.RNode.span(node);
|
|
33
|
+
if (range === undefined || (file !== undefined && node.info.file !== undefined && node.info.file !== file)) {
|
|
34
|
+
continue;
|
|
35
|
+
}
|
|
36
|
+
const [sl, sc, el, ec] = range;
|
|
37
|
+
if (line < sl || line > el || (line === sl && col < sc) || (line === el && col > ec + 1)) {
|
|
38
|
+
continue;
|
|
39
|
+
}
|
|
40
|
+
const extent = (el - sl) * 100_000 + (ec - sc);
|
|
41
|
+
if (extent < size) {
|
|
42
|
+
best = node;
|
|
43
|
+
size = extent;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
return best;
|
|
47
|
+
}
|
|
48
|
+
/** the arguments of a call or an operator, as the nodes of their values */
|
|
49
|
+
function operandsOf(node) {
|
|
50
|
+
if (r_function_call_1.RFunctionCall.is(node)) {
|
|
51
|
+
return node.arguments.flatMap(arg => r_argument_1.RArgument.valueOf(arg) ?? []);
|
|
52
|
+
}
|
|
53
|
+
else if (r_binary_op_1.RBinaryOp.is(node) || r_pipe_1.RPipe.is(node)) {
|
|
54
|
+
return [node.lhs, node.rhs];
|
|
55
|
+
}
|
|
56
|
+
return [];
|
|
57
|
+
}
|
|
58
|
+
/** the name of a call or an operator, `%>%` for both its forms */
|
|
59
|
+
function operatorOf(node) {
|
|
60
|
+
if (r_pipe_1.RPipe.is(node)) {
|
|
61
|
+
return '|>';
|
|
62
|
+
}
|
|
63
|
+
else if (r_binary_op_1.RBinaryOp.is(node)) {
|
|
64
|
+
return node.operator;
|
|
65
|
+
}
|
|
66
|
+
else if (r_function_call_1.RFunctionCall.isNamed(node)) {
|
|
67
|
+
return String(identifier_1.Identifier.getName(node.functionName.content));
|
|
68
|
+
}
|
|
69
|
+
return undefined;
|
|
70
|
+
}
|
|
71
|
+
/** what a layered call like `ggplot(df) + geom_point(aes(...))` takes its data from: the operands of the calls to the left */
|
|
72
|
+
function leftLayers(node) {
|
|
73
|
+
const found = [];
|
|
74
|
+
let at = node;
|
|
75
|
+
while (r_binary_op_1.RBinaryOp.is(at) && at.operator === '+') {
|
|
76
|
+
at = at.lhs;
|
|
77
|
+
}
|
|
78
|
+
if (at !== undefined) {
|
|
79
|
+
found.push(...operandsOf(at));
|
|
80
|
+
}
|
|
81
|
+
return found;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* The data frames whose columns can be written at `node`, nearest first: after `$` the accessed frame, and within
|
|
85
|
+
* an argument flowR knows a call to evaluate within its data (as it does for every quoting call, whether it is
|
|
86
|
+
* `filter`, `subset`, `with`, or `aes`) the other operands of that call, of a pipe into it, and of the layers left of it.
|
|
87
|
+
*/
|
|
88
|
+
function framesFor(node, idMap, dfg) {
|
|
89
|
+
const parent = idMap.get(node.info.parent);
|
|
90
|
+
const access = r_argument_1.RArgument.is(parent) ? idMap.get(parent.info.parent) : undefined;
|
|
91
|
+
if (r_access_1.RAccess.is(access) && (access.operator === '$' || access.operator === '@' || access.operator === '[[') && access.accessed !== node) {
|
|
92
|
+
return { context: DataColumnsContext.Access, candidates: [[access.accessed]] };
|
|
93
|
+
}
|
|
94
|
+
if (!dfg.isQuoted(node.info.id)) {
|
|
95
|
+
return undefined;
|
|
96
|
+
}
|
|
97
|
+
const candidates = [];
|
|
98
|
+
let child = node;
|
|
99
|
+
for (const ancestor of model_1.RNode.iterateParents(node, idMap)) {
|
|
100
|
+
const op = operatorOf(ancestor);
|
|
101
|
+
if (r_function_call_1.RFunctionCall.is(ancestor) || r_binary_op_1.RBinaryOp.is(ancestor) || r_pipe_1.RPipe.is(ancestor)) {
|
|
102
|
+
const around = ancestor.info.parent === undefined ? undefined : idMap.get(ancestor.info.parent);
|
|
103
|
+
const outer = r_argument_1.RArgument.is(around) ? idMap.get(around.info.parent) : around;
|
|
104
|
+
/* the other quoted operands are written in the same data mask (`y = mpg` next to `x = wt` in `aes`), and name columns, not data */
|
|
105
|
+
const level = operandsOf(ancestor).filter(operand => operand !== child && !model_1.RNode.iterateParents(child, idMap).some(p => p === operand) && !dfg.isQuoted(operand.info.id));
|
|
106
|
+
/* the pipe hands its left side on as the first argument */
|
|
107
|
+
if (outer !== undefined && Pipes.has(operatorOf(outer) ?? '') && r_argument_1.RArgument.valueOf(operandsOf(outer)[1]) === ancestor) {
|
|
108
|
+
level.unshift(operandsOf(outer)[0]);
|
|
109
|
+
}
|
|
110
|
+
if (outer !== undefined && r_binary_op_1.RBinaryOp.is(outer) && outer.operator === '+' && outer.rhs === ancestor) {
|
|
111
|
+
level.push(...leftLayers(outer.lhs));
|
|
112
|
+
}
|
|
113
|
+
if (!(op !== undefined && (Pipes.has(op) || Assignments.has(op)))) {
|
|
114
|
+
candidates.push(level);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
child = ancestor;
|
|
118
|
+
}
|
|
119
|
+
return { context: DataColumnsContext.Masked, candidates };
|
|
120
|
+
}
|
|
121
|
+
/** the shape of a frame, if flowR knows any of its columns */
|
|
122
|
+
function frameOf(node, value) {
|
|
123
|
+
if (value === undefined || !value.colnames.isValue()) {
|
|
124
|
+
return undefined;
|
|
125
|
+
}
|
|
126
|
+
const must = [...value.colnames.must];
|
|
127
|
+
const may = value.colnames.isFinite() ? [...value.colnames.may] : [];
|
|
128
|
+
if (must.length + may.length === 0) {
|
|
129
|
+
return undefined;
|
|
130
|
+
}
|
|
131
|
+
return { id: node.info.id, lexeme: model_1.RNode.lexeme(node), must, may, exact: value.colnames.isFinite() && may.length === 0 };
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Executes data columns queries: the data frame shape inference runs once for all of them.
|
|
135
|
+
*/
|
|
136
|
+
async function executeDataColumnsQuery({ analyzer }, queries) {
|
|
137
|
+
const ast = await analyzer.normalize();
|
|
138
|
+
const dfg = (await analyzer.dataflow()).graph;
|
|
139
|
+
const cfg = await analyzer.controlflow();
|
|
140
|
+
const start = Date.now();
|
|
141
|
+
let interpreter;
|
|
142
|
+
const shapeOf = (node) => {
|
|
143
|
+
if (interpreter === undefined) {
|
|
144
|
+
interpreter = new absint_inference_1.AbstractInterpreter({ controlFlow: cfg, dfg, normalizedAst: ast, ctx: analyzer.inspectContext() }, new shape_inference_1.DataFrameShapeAnalysis({ trackOperations: false }));
|
|
145
|
+
interpreter.start();
|
|
146
|
+
}
|
|
147
|
+
return frameOf(node, interpreter.getAbstractValue(node, 'dataFrame'));
|
|
148
|
+
};
|
|
149
|
+
const results = {};
|
|
150
|
+
for (const query of queries) {
|
|
151
|
+
for (const position of query.positions) {
|
|
152
|
+
const [line, col] = position.split(':').map(Number);
|
|
153
|
+
const node = innermostAt(ast.idMap, line, col, query.file);
|
|
154
|
+
const found = node === undefined ? undefined : framesFor(node, ast.idMap, dfg);
|
|
155
|
+
let frames = [];
|
|
156
|
+
/* the nearest call with a data frame of known columns is what the name is evaluated within */
|
|
157
|
+
for (const level of found?.candidates ?? []) {
|
|
158
|
+
frames = level.flatMap(candidate => shapeOf(candidate) ?? []);
|
|
159
|
+
if (frames.length > 0) {
|
|
160
|
+
break;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
results[position] = frames.length === 0 ? { columns: [], frames: [] } : {
|
|
164
|
+
context: found?.context,
|
|
165
|
+
columns: (0, arrays_1.uniqueArray)([...frames.flatMap(f => f.must), ...frames.flatMap(f => f.may)]),
|
|
166
|
+
frames
|
|
167
|
+
};
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
return { ...(0, query_meta_1.metaSince)(start), results };
|
|
171
|
+
}
|
|
172
|
+
/** How the columns can be written at the position. */
|
|
173
|
+
var DataColumnsContext;
|
|
174
|
+
(function (DataColumnsContext) {
|
|
175
|
+
/** as the name accessed of a data frame, `df$col` or `df[["col"]]` */
|
|
176
|
+
DataColumnsContext["Access"] = "access";
|
|
177
|
+
/** as a name a call evaluates within its data, `filter(df, col > 1)` */
|
|
178
|
+
DataColumnsContext["Masked"] = "masked";
|
|
179
|
+
})(DataColumnsContext || (exports.DataColumnsContext = DataColumnsContext = {}));
|
|
180
|
+
function dataColumnsLineParser(_output, line, _config) {
|
|
181
|
+
const positions = (0, slice_query_parser_1.sliceCriteriaParser)(line[0]);
|
|
182
|
+
return {
|
|
183
|
+
query: { type: 'data-columns', positions: positions ?? [] },
|
|
184
|
+
rCode: (0, slice_query_parser_1.queryLineCode)(line, positions ? 1 : 0)
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
exports.DataColumnsQueryDefinition = {
|
|
188
|
+
title: 'Data Columns Query',
|
|
189
|
+
executor: executeDataColumnsQuery,
|
|
190
|
+
asciiSummarizer: (formatter, _analyzer, queryResults, result) => {
|
|
191
|
+
const out = queryResults;
|
|
192
|
+
result.push((0, query_print_1.queryHeader)('data-columns', formatter, out['.meta'].timing));
|
|
193
|
+
for (const [position, at] of Object.entries(out.results)) {
|
|
194
|
+
if (at.context === undefined) {
|
|
195
|
+
result.push(` ╰ ${(0, ansi_1.bold)(position, formatter)}: ${(0, ansi_1.italic)('no data frame in reach', formatter)}`);
|
|
196
|
+
continue;
|
|
197
|
+
}
|
|
198
|
+
const frames = at.frames.map(f => f.lexeme ?? String(f.id)).join(', ');
|
|
199
|
+
result.push(` ╰ ${(0, ansi_1.bold)(position, formatter)} (${at.context} of ${frames}): ${at.columns.join(', ')}`);
|
|
200
|
+
}
|
|
201
|
+
return true;
|
|
202
|
+
},
|
|
203
|
+
fromLine: dataColumnsLineParser,
|
|
204
|
+
completer: slice_query_parser_1.criteriaQueryCompleter,
|
|
205
|
+
syntax: '@data-columns (<line:col>;...) <code | file://path>',
|
|
206
|
+
schema: joi_1.default.object({
|
|
207
|
+
type: joi_1.default.string().valid('data-columns').required().description('The type of the query.'),
|
|
208
|
+
positions: joi_1.default.array().items(joi_1.default.string().pattern(/^\d+:\d+$/)).min(1).required().description('The positions to ask about, as `line:column` of the cursor.'),
|
|
209
|
+
file: joi_1.default.string().optional().description('The file the positions are in, if the analysis holds more than one.')
|
|
210
|
+
}).description('The data columns query returns the columns of a data frame that can be written at a position, after `df$` or within the arguments a call evaluates within its data.'),
|
|
211
|
+
flattenInvolvedNodes: (queryResults) => {
|
|
212
|
+
return Object.values(queryResults.results).flatMap(at => at.frames.map(f => f.id));
|
|
213
|
+
}
|
|
214
|
+
};
|
|
215
|
+
//# sourceMappingURL=data-columns-query-format.js.map
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
-
import type { BaseQueryFormat, BaseQueryResult } from '../../base-query-format';
|
|
1
|
+
import type { BaseQueryFormat, BaseQueryResult, BasicQueryData } from '../../base-query-format';
|
|
2
2
|
import type { DataflowGraph } from '../../../dataflow/graph/graph';
|
|
3
|
-
import { executeDataflowLensQuery } from './dataflow-lens-query-executor';
|
|
4
3
|
import Joi from 'joi';
|
|
4
|
+
/**
|
|
5
|
+
* Executes the given dataflow lens queries using the provided analyzer.
|
|
6
|
+
*/
|
|
7
|
+
export declare function executeDataflowLensQuery({ analyzer }: BasicQueryData, queries: readonly DataflowLensQuery[]): Promise<DataflowLensQueryResult>;
|
|
5
8
|
/**
|
|
6
9
|
* Returns a simplified view on the dataflow graph of the analysis
|
|
7
10
|
*/
|
|
@@ -4,13 +4,49 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.DataflowLensQueryDefinition = void 0;
|
|
7
|
+
exports.executeDataflowLensQuery = executeDataflowLensQuery;
|
|
7
8
|
const query_print_1 = require("../../query-print");
|
|
8
|
-
const dataflow_lens_query_executor_1 = require("./dataflow-lens-query-executor");
|
|
9
9
|
const joi_1 = __importDefault(require("joi"));
|
|
10
10
|
const df_helper_1 = require("../../../dataflow/graph/df-helper");
|
|
11
|
+
const log_1 = require("../../../util/log");
|
|
12
|
+
const query_meta_1 = require("../../query-meta");
|
|
13
|
+
const dfg_view_1 = require("../../../util/simple-df/dfg-view");
|
|
14
|
+
const vertex_1 = require("../../../dataflow/graph/vertex");
|
|
15
|
+
const arguments_1 = require("../../../abstract-interpretation/data-frame/arguments");
|
|
16
|
+
const base_operators_1 = require("../../../dataflow/environments/default-builtin-config/base-operators");
|
|
17
|
+
/**
|
|
18
|
+
* The lens hides syntax: every operator R has, the native pipe (which {@link BuiltInOperators.byName} does not list), and the
|
|
19
|
+
* control-flow keywords. None of them names anything, unlike the built-in *functions* (`print`, `ifelse`) it keeps.
|
|
20
|
+
* Anchored and escaped, as most of these are regex syntax themselves and an unanchored alternative would also drop
|
|
21
|
+
* every lexeme merely *containing* one (`if` in `identifier`).
|
|
22
|
+
*/
|
|
23
|
+
const HiddenLexemes = `^(${[...Object.keys(base_operators_1.BuiltInOperators.byName), '|>', 'function', 'repeat', 'if', 'next', 'break']
|
|
24
|
+
.map(name => (0, arguments_1.escapeRegExp)(name)).join('|')})$`;
|
|
25
|
+
/**
|
|
26
|
+
* Executes the given dataflow lens queries using the provided analyzer.
|
|
27
|
+
*/
|
|
28
|
+
async function executeDataflowLensQuery({ analyzer }, queries) {
|
|
29
|
+
if (queries.length !== 1) {
|
|
30
|
+
log_1.log.warn('Dataflow query expects only up to one query, but got', queries.length);
|
|
31
|
+
}
|
|
32
|
+
const now = Date.now();
|
|
33
|
+
const simplifiedGraph = (0, dfg_view_1.reduceDfg)((await analyzer.dataflow()).graph, {
|
|
34
|
+
vertices: {
|
|
35
|
+
keepEnv: false,
|
|
36
|
+
keepCd: true,
|
|
37
|
+
tags: [vertex_1.VertexType.Use, vertex_1.VertexType.VariableDefinition, vertex_1.VertexType.FunctionDefinition, vertex_1.VertexType.FunctionCall],
|
|
38
|
+
nameRegex: HiddenLexemes,
|
|
39
|
+
blacklistWithName: true
|
|
40
|
+
}
|
|
41
|
+
}, analyzer.inspectContext().env.makeCleanEnv());
|
|
42
|
+
return {
|
|
43
|
+
...(0, query_meta_1.metaSince)(now),
|
|
44
|
+
simplifiedGraph
|
|
45
|
+
};
|
|
46
|
+
}
|
|
11
47
|
exports.DataflowLensQueryDefinition = {
|
|
12
48
|
title: 'Dataflow Lens Query',
|
|
13
|
-
executor:
|
|
49
|
+
executor: executeDataflowLensQuery,
|
|
14
50
|
asciiSummarizer: (formatter, _analyzer, queryResults, result) => {
|
|
15
51
|
const out = queryResults;
|
|
16
52
|
result.push((0, query_print_1.queryHeader)('dataflow-lens', formatter, out['.meta'].timing));
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
import type { BaseQueryFormat, BaseQueryResult } from '../../base-query-format';
|
|
1
|
+
import type { BaseQueryFormat, BaseQueryResult, BasicQueryData } from '../../base-query-format';
|
|
2
2
|
import type { DataflowGraph } from '../../../dataflow/graph/graph';
|
|
3
|
-
import { executeDataflowQuery } from './dataflow-query-executor';
|
|
4
3
|
import Joi from 'joi';
|
|
5
4
|
import type { NodeId } from '../../../r-bridge/lang-4.x/ast/model/processing/node-id';
|
|
5
|
+
/**
|
|
6
|
+
* Executes the given dataflow queries.
|
|
7
|
+
*/
|
|
8
|
+
export declare function executeDataflowQuery({ analyzer }: BasicQueryData, queries: readonly DataflowQuery[]): Promise<DataflowQueryResult>;
|
|
6
9
|
/**
|
|
7
10
|
* Simple re-returns the dataflow graph of the analysis.
|
|
8
11
|
*/
|
|
@@ -4,15 +4,31 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.DataflowQueryDefinition = void 0;
|
|
7
|
+
exports.executeDataflowQuery = executeDataflowQuery;
|
|
7
8
|
const query_print_1 = require("../../query-print");
|
|
8
|
-
const dataflow_query_executor_1 = require("./dataflow-query-executor");
|
|
9
9
|
const joi_1 = __importDefault(require("joi"));
|
|
10
10
|
const df_helper_1 = require("../../../dataflow/graph/df-helper");
|
|
11
|
+
const log_1 = require("../../../util/log");
|
|
12
|
+
const query_meta_1 = require("../../query-meta");
|
|
13
|
+
/**
|
|
14
|
+
* Executes the given dataflow queries.
|
|
15
|
+
*/
|
|
16
|
+
async function executeDataflowQuery({ analyzer }, queries) {
|
|
17
|
+
if (queries.length !== 1) {
|
|
18
|
+
log_1.log.warn('Dataflow query expects only up to one query, but got', queries.length);
|
|
19
|
+
}
|
|
20
|
+
const startTime = Date.now();
|
|
21
|
+
const { graph } = await analyzer.dataflow();
|
|
22
|
+
return {
|
|
23
|
+
...(0, query_meta_1.metaSince)(startTime),
|
|
24
|
+
graph: queries.every(q => q.environments === false) ? graph.withoutEnvironments() : graph
|
|
25
|
+
};
|
|
26
|
+
}
|
|
11
27
|
/** Above this many characters, the mermaid.live link is dropped from the REPL output (large graphs produce megabyte-sized base64 urls). */
|
|
12
28
|
const MaxMermaidUrlLength = 8000;
|
|
13
29
|
exports.DataflowQueryDefinition = {
|
|
14
30
|
title: 'Dataflow Query',
|
|
15
|
-
executor:
|
|
31
|
+
executor: executeDataflowQuery,
|
|
16
32
|
asciiSummarizer: (formatter, _analyzer, queryResults, result) => {
|
|
17
33
|
const out = queryResults;
|
|
18
34
|
result.push((0, query_print_1.queryHeader)('dataflow', formatter, out['.meta'].timing));
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { type DataflowGraphVertexFunctionCall } from '../../../dataflow/graph/vertex';
|
|
2
|
+
import { type BrandedIdentifier } from '../../../dataflow/environments/identifier';
|
|
2
3
|
import { NodeId } from '../../../r-bridge/lang-4.x/ast/model/processing/node-id';
|
|
3
4
|
import type { NormalizedAst } from '../../../r-bridge/lang-4.x/ast/model/processing/decorate';
|
|
4
5
|
import type { DataflowInformation } from '../../../dataflow/info';
|
|
5
6
|
/** The variable an assignment stores a result in. */
|
|
6
7
|
export interface AssignmentTarget {
|
|
7
8
|
readonly id: NodeId;
|
|
8
|
-
readonly name:
|
|
9
|
+
readonly name: BrandedIdentifier;
|
|
9
10
|
}
|
|
10
11
|
/**
|
|
11
12
|
* What the dependencies query asks about the same calls again and again (the roles of their arguments, whether a
|
|
@@ -15,7 +16,7 @@ export interface FlowMemo {
|
|
|
15
16
|
readonly roles: Map<NodeId, [NodeId, number][]>;
|
|
16
17
|
readonly plots: Map<NodeId, boolean>;
|
|
17
18
|
readonly assignments: Map<NodeId, AssignmentTarget | undefined>;
|
|
18
|
-
readonly inputs: Map<NodeId, ReadonlySet<
|
|
19
|
+
readonly inputs: Map<NodeId, ReadonlySet<BrandedIdentifier>>;
|
|
19
20
|
}
|
|
20
21
|
/** A fresh {@link FlowMemo}, to be dropped with the query run it serves. */
|
|
21
22
|
export declare function makeFlowMemo(): FlowMemo;
|
|
@@ -30,9 +31,9 @@ export declare function argumentRoles(dataflow: DataflowInformation, call: Dataf
|
|
|
30
31
|
* input (the file of `write.csv`, a flag, a callee), nor is what a call quotes or looks up in a data mask (`x` in
|
|
31
32
|
* `filter(df, x > 1)`), or a use that only names a function.
|
|
32
33
|
*/
|
|
33
|
-
export declare function inputVariablesOf(dataflow: DataflowInformation, ast: NormalizedAst, call: DataflowGraphVertexFunctionCall, memo?: FlowMemo):
|
|
34
|
+
export declare function inputVariablesOf(dataflow: DataflowInformation, ast: NormalizedAst, call: DataflowGraphVertexFunctionCall, memo?: FlowMemo): BrandedIdentifier[];
|
|
34
35
|
/** The variables the value `id` is computed from: those of {@link inputVariablesOf} for a call, the variable itself for a use. */
|
|
35
|
-
export declare function inputVariablesAt(dataflow: DataflowInformation, ast: NormalizedAst, id: NodeId, memo?: FlowMemo):
|
|
36
|
+
export declare function inputVariablesAt(dataflow: DataflowInformation, ast: NormalizedAst, id: NodeId, memo?: FlowMemo): BrandedIdentifier[];
|
|
36
37
|
/**
|
|
37
38
|
* The arguments the call hands on as its own result: the {@link ArgProp.Alias} one of its signature (`(x)`, a pipe
|
|
38
39
|
* into a call), or both operands of a `+` that adds to a plot, as ggplot's method for it returns the plot.
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { type DependenciesQuery, type DependenciesQueryResult } from './dependencies-query-format';
|
|
2
2
|
import { type DataflowGraphVertexFunctionCall } from '../../../dataflow/graph/vertex';
|
|
3
|
-
import { Identifier } from '../../../dataflow/environments/identifier';
|
|
3
|
+
import { Identifier, type BrandedIdentifier } from '../../../dataflow/environments/identifier';
|
|
4
4
|
import { NodeId } from '../../../r-bridge/lang-4.x/ast/model/processing/node-id';
|
|
5
5
|
import type { BasicQueryData } from '../../base-query-format';
|
|
6
|
+
import { type OpenedResources } from '../../../dataflow/eval/resolve/resolve-argument';
|
|
6
7
|
import type { DataflowInformation } from '../../../dataflow/info';
|
|
7
8
|
import type { FlowrConfig } from '../../../config';
|
|
8
9
|
import type { NormalizedAst } from '../../../r-bridge/lang-4.x/ast/model/processing/decorate';
|
|
@@ -22,9 +23,11 @@ export interface QueryRun {
|
|
|
22
23
|
readonly normalize: NormalizedAst;
|
|
23
24
|
readonly memo: FlowMemo;
|
|
24
25
|
/** the formals of the call, give its qualified name if known already */
|
|
25
|
-
readonly formals: (vertex: DataflowGraphVertexFunctionCall, qualified?: Identifier) => readonly
|
|
26
|
+
readonly formals: (vertex: DataflowGraphVertexFunctionCall, qualified?: Identifier) => readonly BrandedIdentifier[] | undefined;
|
|
26
27
|
/** how the values of the entries of a call come about, so a call of the function around it can ask again for its own */
|
|
27
28
|
readonly revalue: Map<NodeId, Revalue>;
|
|
29
|
+
/** what the arguments read from, asked for again with every call context */
|
|
30
|
+
readonly opened: OpenedResources;
|
|
28
31
|
}
|
|
29
32
|
/** the values the entries of a call get when the functions around it are resolved for the calls the context names */
|
|
30
33
|
type Revalue = (callContext: CallContext) => readonly string[] | undefined;
|
|
@@ -70,7 +70,7 @@ async function executeDependenciesQuery({ analyzer, }, queries) {
|
|
|
70
70
|
await (0, query_1.executeQueriesOfSameType)(data, functions.entries().flatMap(makeCallContextQuery).toArray());
|
|
71
71
|
const g = (0, dependencies_query_format_1.getAllCategories)(queries, ctx);
|
|
72
72
|
const enabled = query.enabledCategories;
|
|
73
|
-
const run = { dataflow, config, normalize, memo: (0, data_flow_1.makeFlowMemo)(), formals: formalsLookup(dataflow.graph, ctx), revalue: new Map() };
|
|
73
|
+
const run = { dataflow, config, normalize, memo: (0, data_flow_1.makeFlowMemo)(), formals: formalsLookup(dataflow.graph, ctx), revalue: new Map(), opened: new Map() };
|
|
74
74
|
/* the packages the code attaches decide which package a bare call further down belongs to */
|
|
75
75
|
const library = getResults(g, run, queryResults, 'library', functions.get('library') ?? [], data);
|
|
76
76
|
const attaching = library.filter(library_functions_1.attachesPackage);
|
|
@@ -207,7 +207,7 @@ function assumedBasePackageEntries(dfg, rVersion, explicit) {
|
|
|
207
207
|
const usedBy = Map.groupBy(used, u => u.pkg);
|
|
208
208
|
return (0, r_base_packages_1.attachedBasePackages)(rVersion).filter(pkg => usedBy.has(pkg)).map(pkg => (0, objects_1.compactRecord)({
|
|
209
209
|
functionName: dependencies_query_format_1.Attached,
|
|
210
|
-
value: pkg,
|
|
210
|
+
value: String(pkg),
|
|
211
211
|
implicit: true,
|
|
212
212
|
alwaysAttached: pkg === "base" /* PkgName.Base */ ? true : undefined,
|
|
213
213
|
linkedIds: usedBy.get(pkg)?.map(u => u.id)
|
|
@@ -310,8 +310,8 @@ function getResults(categories, run, results, kind, functions, data, attaching =
|
|
|
310
310
|
continue;
|
|
311
311
|
}
|
|
312
312
|
const formals = run.formals(vertex, functionName);
|
|
313
|
-
const argsIn = (callContext) => (0, resolve_argument_1.getArgumentStringValue)(vars, dfg, vertex, info.argIdx, info.argName, info.resolveValue, ictx, formals, callContext);
|
|
314
|
-
const linkedIn = (args, callContext) => collectValuesFromLinks(args, { dataflow, config, ctx: ictx, formals: run.formals }, linkedIds, callContext);
|
|
313
|
+
const argsIn = (callContext) => (0, resolve_argument_1.getArgumentStringValue)(vars, dfg, vertex, info.argIdx, info.argName, info.resolveValue, ictx, formals, callContext, run.opened);
|
|
314
|
+
const linkedIn = (args, callContext) => collectValuesFromLinks(args, { dataflow, config, ctx: ictx, formals: run.formals, opened: run.opened }, linkedIds, callContext);
|
|
315
315
|
const args = argsIn();
|
|
316
316
|
const linkedArgs = linkedIn(args);
|
|
317
317
|
const linked = linkedIds?.map(linkedId => typeof linkedId === 'object' ? linkedId.id : linkedId);
|
|
@@ -411,7 +411,7 @@ function collectValuesFromLinks(args, data, linkedIds, callContext) {
|
|
|
411
411
|
if (!vertex_1.DfgVertex.isFunctionCall(vertex)) {
|
|
412
412
|
continue;
|
|
413
413
|
}
|
|
414
|
-
const args = (0, resolve_argument_1.getArgumentStringValue)(data.config.solver.variables, data.dataflow.graph, vertex, info.argIdx, info.argName, info.resolveValue, data.ctx, data.formals(vertex), callContext);
|
|
414
|
+
const args = (0, resolve_argument_1.getArgumentStringValue)(data.config.solver.variables, data.dataflow.graph, vertex, info.argIdx, info.argName, info.resolveValue, data.ctx, data.formals(vertex), callContext, data.opened);
|
|
415
415
|
for (const [arg, values] of args?.entries() ?? []) {
|
|
416
416
|
map.set(arg, (map.get(arg) ?? new Set()).union(values));
|
|
417
417
|
}
|
|
@@ -10,6 +10,7 @@ import type { CallContextQueryResult } from '../call-context-query/call-context-
|
|
|
10
10
|
import type { Range } from 'semver';
|
|
11
11
|
import type { AsyncOrSync, MarkOptional } from 'ts-essentials';
|
|
12
12
|
import type { NamespaceInfo } from '../../../project/plugins/file-plugins/files/flowr-namespace-file';
|
|
13
|
+
import type { BrandedIdentifier } from '../../../dataflow/environments/identifier';
|
|
13
14
|
import { Identifier } from '../../../dataflow/environments/identifier';
|
|
14
15
|
import type { ReadOnlyFlowrAnalyzerContext } from '../../../project/context/flowr-analyzer-context';
|
|
15
16
|
export { Constant, Unknown } from './dependency-values';
|
|
@@ -32,7 +33,7 @@ export interface DependencyCategorySettings {
|
|
|
32
33
|
additionalAnalysis?: (data: BasicQueryData, ignoreDefault: boolean, functions: readonly FunctionInfo[], queryResults: CallContextQueryResult, result: DependencyInfo[]) => AsyncOrSync<void>;
|
|
33
34
|
}
|
|
34
35
|
/** the built-in categories; what each searches for is derived per configuration, see {@link defaultDependencyCategories} */
|
|
35
|
-
export declare const DefaultDependencyCategoryNames: readonly ["library", "remote", "source", "read", "write", "visualize", "transform", "test", "statistics"];
|
|
36
|
+
export declare const DefaultDependencyCategoryNames: readonly ["library", "remote", "source", "read", "write", "visualize", "transform", "test", "statistics", "interactive"];
|
|
36
37
|
export type DefaultDependencyCategoryName = typeof DefaultDependencyCategoryNames[number];
|
|
37
38
|
/**
|
|
38
39
|
* The categories flowR searches for by default. The functions of the categories flowR derives from its
|
|
@@ -104,13 +105,13 @@ export interface DependencyInfo extends Record<string, unknown> {
|
|
|
104
105
|
* `df |> filter(x > 1)` (where `x` names a column) and `a`, `b` for `left_join(a, b)`; an addon to a plot draws its
|
|
105
106
|
* data. Reported for the `write`, `visualize` and `transform` categories.
|
|
106
107
|
*/
|
|
107
|
-
inputVariables?: readonly
|
|
108
|
+
inputVariables?: readonly BrandedIdentifier[];
|
|
108
109
|
/**
|
|
109
110
|
* The variable the result of the call is assigned to, following every call that hands it on (a pipe into a call,
|
|
110
111
|
* `( )`, a `+` adding to a plot) up to `<-`, `=` or `->`.
|
|
111
112
|
* Reported for the `read`, `visualize` and `transform` categories.
|
|
112
113
|
*/
|
|
113
|
-
assignedTo?:
|
|
114
|
+
assignedTo?: BrandedIdentifier;
|
|
114
115
|
/** for a plot, the title its `ggtitle`, `labs(title = )` or `main =` states */
|
|
115
116
|
title?: string;
|
|
116
117
|
/** for a plot, the file it is written to by `ggsave` or by a graphics device open when it is drawn */
|
|
@@ -26,7 +26,8 @@ const read_functions_1 = require("./function-info/read-functions");
|
|
|
26
26
|
const write_functions_1 = require("./function-info/write-functions");
|
|
27
27
|
const visualize_functions_1 = require("./function-info/visualize-functions");
|
|
28
28
|
const transform_functions_1 = require("./function-info/transform-functions");
|
|
29
|
-
const
|
|
29
|
+
const tagged_functions_1 = require("./function-info/tagged-functions");
|
|
30
|
+
const built_in_props_1 = require("../../../dataflow/environments/built-in-props");
|
|
30
31
|
const test_functions_1 = require("./function-info/test-functions");
|
|
31
32
|
const identifier_1 = require("../../../dataflow/environments/identifier");
|
|
32
33
|
const r_project_1 = require("../../../r-bridge/lang-4.x/ast/model/nodes/r-project");
|
|
@@ -44,7 +45,7 @@ Object.defineProperty(exports, "Unknown", { enumerable: true, get: function () {
|
|
|
44
45
|
/** {@link DependencyInfo#functionName} for an assumed base package: nothing in the code names it, so there is no call to report as `functionName`. */
|
|
45
46
|
exports.Attached = '<attached>';
|
|
46
47
|
/** the built-in categories; what each searches for is derived per configuration, see {@link defaultDependencyCategories} */
|
|
47
|
-
exports.DefaultDependencyCategoryNames = ['library', 'remote', 'source', 'read', 'write', 'visualize', 'transform', 'test', 'statistics'];
|
|
48
|
+
exports.DefaultDependencyCategoryNames = ['library', 'remote', 'source', 'read', 'write', 'visualize', 'transform', 'test', 'statistics', 'interactive'];
|
|
48
49
|
/** a definition or call reached again while working it out makes nothing new */
|
|
49
50
|
const NothingNew = { answer: false };
|
|
50
51
|
/**
|
|
@@ -147,7 +148,7 @@ const dependencyCategoriesOf = (env) => ({
|
|
|
147
148
|
result.push({
|
|
148
149
|
nodeId: node.info.id,
|
|
149
150
|
functionName: model_1.RNode.lexeme(node).includes(':::') ? ':::' : '::',
|
|
150
|
-
value: ns,
|
|
151
|
+
value: String(ns),
|
|
151
152
|
versionConstraints: dep?.versionConstraints,
|
|
152
153
|
derivedRange: dep?.effectiveRange,
|
|
153
154
|
namespaceInfo: dep?.namespaceInfo
|
|
@@ -217,7 +218,11 @@ const dependencyCategoriesOf = (env) => ({
|
|
|
217
218
|
},
|
|
218
219
|
'statistics': {
|
|
219
220
|
queryDisplayName: 'Statistics',
|
|
220
|
-
functions: (0,
|
|
221
|
+
functions: (0, tagged_functions_1.functionsTagged)(env.builtInIndex, built_in_props_1.SemanticCallTag.Statistics)
|
|
222
|
+
},
|
|
223
|
+
'interactive': {
|
|
224
|
+
queryDisplayName: 'Interactive Use',
|
|
225
|
+
functions: (0, tagged_functions_1.functionsTagged)(env.builtInIndex, built_in_props_1.SemanticCallTag.Interactive)
|
|
221
226
|
}
|
|
222
227
|
});
|
|
223
228
|
function printResultSection(title, infos, result, formatter) {
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
import type { BrandedIdentifier, BrandedNamespace } from '../../../../dataflow/environments/identifier';
|
|
1
2
|
import type { CallNameTypes, LinkTo } from '../../call-context-query/call-context-query-format';
|
|
3
|
+
import type { ResolveMode } from '../../../../dataflow/eval/resolve/resolve-argument';
|
|
2
4
|
/** when to read the argument value from a linked function */
|
|
3
5
|
export declare enum DependencyInfoLinkConstraint {
|
|
4
6
|
Always = "always",
|
|
@@ -15,15 +17,15 @@ export type DependencyInfoLinkAttachedInfo = DependencyInfoLink['attachLinkInfo'
|
|
|
15
17
|
export interface FunctionArgInfo {
|
|
16
18
|
/** the index if the argument can be positional, unnamed in case of something like `...`, if the argument must be given with the name, please leave undefined */
|
|
17
19
|
argIdx?: number | 'unnamed';
|
|
18
|
-
argName?:
|
|
19
|
-
resolveValue?:
|
|
20
|
+
argName?: BrandedIdentifier;
|
|
21
|
+
resolveValue?: ResolveMode;
|
|
20
22
|
}
|
|
21
23
|
/** Describes a function that may create a dependency */
|
|
22
24
|
export interface FunctionInfo extends FunctionArgInfo {
|
|
23
25
|
/** Which package does the function belong to */
|
|
24
|
-
package?:
|
|
26
|
+
package?: BrandedNamespace;
|
|
25
27
|
/** The name of the function */
|
|
26
|
-
name:
|
|
28
|
+
name: BrandedIdentifier;
|
|
27
29
|
/** links to other function calls to get the dependency from there (e.g., with `sink` for `print`) */
|
|
28
30
|
linkTo?: DependencyInfoLink[];
|
|
29
31
|
/** default value for the argument if no binding value is found, please be aware, that categories can define global defaults, these are overwritten by the per-function defaults */
|
|
@@ -19,7 +19,7 @@ exports.OtherPathFunctions = [
|
|
|
19
19
|
{ package: 'base', name: 'file.symlink', argIdx: 0, argName: 'from', resolveValue: true },
|
|
20
20
|
{ package: 'base', name: 'file.link', argIdx: 0, argName: 'from', resolveValue: true },
|
|
21
21
|
{ package: 'base', name: 'Sys.junction', argIdx: 0, argName: 'from', resolveValue: true },
|
|
22
|
-
{ package: 'base', name: 'dir.exists', argIdx: 0, argName: '
|
|
22
|
+
{ package: 'base', name: 'dir.exists', argIdx: 0, argName: 'paths', resolveValue: true },
|
|
23
23
|
{ package: 'base', name: 'list.files', argIdx: 0, argName: 'path', resolveValue: true, defaultValue: '.' },
|
|
24
24
|
{ package: 'base', name: 'list.dirs', argIdx: 0, argName: 'path', resolveValue: true, defaultValue: '.' },
|
|
25
25
|
{ package: 'base', name: 'dir', argIdx: 0, argName: 'path', resolveValue: true, defaultValue: '.' }
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { FunctionInfo } from './function-info';
|
|
2
|
+
import type { SemanticCallTag } from '../../../../dataflow/environments/built-in-props';
|
|
3
|
+
import type { BuiltInIndex } from '../../../../dataflow/environments/query-fn-props';
|
|
4
|
+
/**
|
|
5
|
+
* The built-ins labeled `tag`, as the entries of a dependency category, so the dependency query and the built-in
|
|
6
|
+
* configuration cannot disagree about them: the statistical tests are the ones labeled {@link SemanticCallTag.Statistics},
|
|
7
|
+
* the calls needing an interactive session those labeled {@link SemanticCallTag.Interactive}. Every one of them names
|
|
8
|
+
* the package it belongs to, which is what keeps `stats::t.test` a test and drops a `t.test` of somebody else's package.
|
|
9
|
+
* Label a built-in with the tag and it shows up in the category.
|
|
10
|
+
*/
|
|
11
|
+
export declare function functionsTagged(index: BuiltInIndex, tag: SemanticCallTag): FunctionInfo[];
|