ref: d052b8be7485d34e4349c80b43cda34f574e7cd8
parent: c677bdf1701a7207c8756a673c8795408a18a7da
author: Ori Bernstein <ori@eigenstate.org>
date: Thu Jul 6 17:17:26 EDT 2017
Cleaner version of the termination condition. It isn't entirely equivalent, but the cases where it returns true should be the same.
--- a/parse/type.c
+++ b/parse/type.c
@@ -727,8 +727,8 @@
if (a->tid == b->tid)
return 1;
- if (bshas(avisited, a->tid) || bshas(bvisited, b->tid))
- return bshas(avisited, a->tid) == bshas(bvisited, b->tid);
+ if (bshas(avisited, a->tid) && bshas(bvisited, b->tid))
+ return 1;
bsput(avisited, a->tid);
bsput(bvisited, b->tid);