type erasure improved, still incomplete