After this patch, in the following snippet:
template <typename T> Foo {}; template <template <typename T> class CT = Foo> Bar {}; Bar<> b;
The debug-info entry for the CT template parameter will have
a DW_AT_default_value (true) attached to it.
Differential D139989
[clang][DebugInfo] Add DW_AT_default_value support for template template parameters Michael137 on Dec 13 2022, 5:53 PM. Authored by
Details After this patch, in the following snippet: template <typename T> Foo {}; template <template <typename T> class CT = Foo> Bar {}; Bar<> b; The debug-info entry for the CT template parameter will have
Diff Detail
Event Timeline
Comment Actions Looks good to me - we'd usually split the LLVM part from the Clang part, but I don't think we have fine grained unit tests for DIBuilder (could you check - if we do, then the LLVM part should go separately, with unit test coverage, then the Clang part can go in that uses it) & /maybe/ it's worth having a default value for the IsDefault argument, so any existing callers aren't broken, but I don't feel strongly about it if it all works, the number of external callers is probably quite small/not a big deal. (if you do split up the clang/llvm parts into separate commits, no need to send them as separate reviews - you can commit them directly) |