[clang][DebugInfo] Attach DW_AT_default_value to template arg metadata regardless of DwarfVersion
**Summary** Starting with DWARFv5, DW_AT_default_value can be used to indicate that a template argument has a default value. With this patch Clang will attach the attribute to the debug metadata regardless of version. In a follow-up patch we will change llvm to emit this attribute in earlier versions of DWARF, unless compiling with -gstrict-dwarf. **Details** * Previously the DwarfVersion check in CGDebugInfo was inconsistent: For non-type template arguments we attached the attribute to the debug metadata in DWARFv5 only. Whereas for type template arguments we didn't have such a version restriction. With this patch we attach the attribute regardless of DWARF version (and instead offload the check to the AsmPrinter in a future patch).
Loading
Please sign in to comment