Hand rolled equals for TypeRef

Avoids the instanceOf tax incurred by == in
List#equals.
Use .equals rather than == in internal.util.WeakHashSet