Fix bug causing cyclic lists. Still some defthm issues.