Detect if clauses that contradict each other. This is useful to detect if clauses that are not satistifable.

detect_contradicting_if_rules(x, ..., verbose = TRUE)

Arguments

x

A validator object.

...

Additional arguments passed to detect_if_clauses.

verbose

Logical. If TRUE, print the results.

Value

A list of contradictions found in the if clauses, or NULL if none are found.

Examples

rules <- validator(
  if (nace == "a") export == "y",
  if (nace == "a")  export == "n"
)

detect_contradicting_if_rules(rules)
#> 1 contradiction(s) with if clauses found:
#> When nace == "a":
#>   V1: if (nace == "a") export == "y"
#>   V2: if (nace == "a") export == "n"