Dereferencing: use new SchemaKey constructors

Also make SchemaTreeEquivalence deprecated; not needed anymore.