DebugInfo: Name class templates with default arguments consistently (both...
DebugInfo: Name class templates with default arguments consistently (both direct naming, and as a template argument for a function template) It's noteworthy that GCC has the same bug here, which is a bit surprising. Both Clang and GCC's bug is only for function template arguments that are themselves templates with default template arguments (f1<t1<int[, missing_default_here]>>). Probably because function name matching isn't generally necessary - whereas type matching is necessary for DWARF consumers to associate declarations and definitions across translation units, so the bug's been addressed there already - but continued to exist for function templates since it's fairly benign there. I came across this while working on a change that could reconstitute these pretty printed names based on the rest of the DWARF, reducing the size of the DWARF by not having to encode all the template parameters in the name string. That reconstitution code can't tell the difference between a defaulted argument or not, so couldn't create the current buggy-ish output. Making the names more consistent between direct and indirect references, and between function and class templates seems all to the good. (I fixed the function template version of this a few years back in 9fdd09a4 - clearly I should've looked more closely and generalized the code better so it only had to be fixed once - well, doing that here now)
Loading
Please sign in to comment