changes to c category hierarchy code