Fix record type querying - now uses CanonicalType like the other LEAF_TYPES