Holds if elements
y are candidates for testing structural
Subclasses are expected to override this predicate to identify the top-level elements which they want to compare. Care should be taken to avoid identifying too many pairs of elements, as in general there are very many structurally equal subtrees in a program, and in order to keep the computation feasible we must focus attention.
Note that this relation is not expected to be symmetric – it’s
fine to include a pair
(x, y) but not
In fact, not including the symmetrically implied fact will save
half the computation time on the structural comparison.