Skip to content

Commit

Permalink
fix: normalize graph in one place
Browse files Browse the repository at this point in the history
  • Loading branch information
averissimo committed Oct 16, 2024
1 parent 8b5e76e commit 0a894df
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions R/utils-get_code_dependency.R
Original file line number Diff line number Diff line change
Expand Up @@ -382,10 +382,12 @@ extract_side_effects <- function(calls_pd) {
graph_parser <- function(x, graph) {
# normalize x to remove surrounding backticks
x <- gsub("^`|`$", "", x)
graph <- lapply(graph, function(call) gsub("^`|`$", "", call))
occurrence <- vapply(
graph, function(call) {
graph,
function(call) {
ind <- match("<-", call, nomatch = length(call) + 1L)
x %in% gsub("^`|`$", "", call[seq_len(ind - 1L)])
x %in% call[seq_len(ind - 1L)]
},
logical(1)
)
Expand Down
2 changes: 1 addition & 1 deletion man/cdisc_data.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 0a894df

Please sign in to comment.