A further note on looping in Prolog

  • Authors:
  • Michael A. Covington

  • Affiliations:
  • The University of Georgia, Athens, Georgia

  • Venue:
  • ACM SIGPLAN Notices
  • Year:
  • 1985

Quantified Score

Hi-index 0.00

Visualization

Abstract

In an earlier paper (Covington 1984) I proposed that looping in Prolog should be prevented by blocking all derivations in which the current goal matches a higher goal. This is too strong a constraint; it causes exhaustive searches to be incomplete. A better approach is to block all derivations in which the current goal matches a higher goal and is about to be evaluted using the same rule as was used to evaluate the higher goal. This is sufficient to block looping, and produces otherwise correct behavior, in all of the cases mentioned in the earlier paper.