fix detection of TypeClass during bootstrap