Skip to content

Commit

Permalink
Handle large value references in get_value_reference_map(). Fix #50.
Browse files Browse the repository at this point in the history
  • Loading branch information
Hongyuan Jia committed May 30, 2019
1 parent 4978ec4 commit 448f551
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion R/parse.R
Original file line number Diff line number Diff line change
Expand Up @@ -1498,7 +1498,7 @@ get_value_reference_map <- function (map, src, value, all = TRUE) {
if (!nrow(val_ref)) return(empty)

# get field reference map in current IDF
val_ref_map <- val_ref[map, on = "field_id", nomatch = 0L]
val_ref_map <- val_ref[map, on = "field_id", nomatch = 0L, allow.cartesian = TRUE]
set(val_ref_map, NULL, "src_enum", NULL)

# get all values in lower case that are sources
Expand Down
1 change: 1 addition & 0 deletions R/validate.R
Original file line number Diff line number Diff line change
Expand Up @@ -459,6 +459,7 @@ check_incomplete_extensible <- function (idd_env, idf_env, env_in) {
by = list(cumsum(!is.na(can_be_na)), object_id)]
empty_info[is.na(can_be_na), can_be_na := TRUE]
incomplete <- empty_info[has_any_na == TRUE & can_be_na == FALSE, list(object_id, extensible_group)]
setorderv(incomplete, names(incomplete))

if (nrow(incomplete)) {
add_validity(idd_env, idf_env, env_in, incomplete, "incomplete_extensible", c("object_id", "extensible_group"))
Expand Down

0 comments on commit 448f551

Please sign in to comment.