Relax circular elimination check #7
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
When using
#show
statements, there is a check to prevent circularly defined predicates from being eliminated when they are requested to be hidden.The reason is that for a program
just
#show
ingr(X)
andp(X)
is possible by replacing all occurrences of the now hidden predicateq(X)
by its definitionp(X)
:This doesn’t work when attempting only to
#show
r(X)
. This is becausep(X)
has a circular definition and cannot be eliminated by substitution.However, this check is too strict. If the program looked as follows:
then only
#show
ingr(X)
should be allowed. This is because no formula other than the definitions ofp(X)
andq(X)
refer to hidden predicates, and both of these rules would be hidden anyway after eliminatingp(X)
andq(X)
. Hence, it’s valid to print the following output in this case:As of now, anthem fails in such cases, complaining about the seeming circular dependency.