Fix nested named classes.