one question about up reference

I have one question about up reference, why use \nested_level_count in type description.
and have to handle it in HandleUpRefs() (AsmParser/llvmAsmParser.y) ,

why not just insert type name and return in calcTypeName() (AsmWriter.cpp) ;

As you mention in "How to build recursively type" ,

%mylist = type { %mylist*, int } is accepted .

Is it neccessary to use \nested_level_count ?

I'm very thankful if you can give me some C code example to show it .


Upreferences are used when the symbol table is stripped. The above type can be written like this without a name:

  {\2*, int}

This is important because LLVM does not require every type to have a name, but I wouldn't recommend language front-ends to generate these.