It occurred to me today that I could use current_class_name rather than TYPE_IDENTIFIER (current_class_type). Tested x86_64-pc-linux-gnu, applied to trunk.