use dict as TypeRegister + add warning for duplicates