Code-Inspect / flowr

A program slicer and dataflow analyzer for the R programming language.
https://github.com/Code-Inspect/flowr/wiki
GNU General Public License v3.0
14 stars 2 forks source link

Allow specifying slicing points more loosely #704

Open Ellpeck opened 4 months ago

Ellpeck commented 4 months ago

See this comment on vscode-flowr. Finding the beginning of a token is currently hacky there, and a nice fix for this issue would be allowing a less specific slicing point format than line:col

EagleoutIce commented 2 months ago

What i want is a format like token@12:3 or in other words a criteration which selects a token that contains that position. Currently 12:3 checks for a token that starts at the given position (with a little bit of automatic selection on wrapper elements). However, if we, for example specify 12:3 but line 12 looks like this: longvariable <- 3, then we are not finding the token (correctly). What i want is a different format which checks for inclusion and selects longvariable (i.e. maps to the internal id of the symbol token).