[PATCH] D52057: Emit template type and value parameter DIEs for template variables.

Matthew Voss via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 18 14:20:13 PDT 2018


ormris added inline comments.


================
Comment at: test/DebugInfo/X86/template.ll:20
+; CHECK: DW_TAG_variable
+; CHECK-NEXT: DW_AT_name{{.*}}"var"
 ; CHECK-NOT: NULL
----------------
ormris wrote:
> dblaikie wrote:
> > ormris wrote:
> > > dblaikie wrote:
> > > > Presumably this should actually be named 'var<int>'? Not a big deal, since this is just using whatever name is in the IR To begin with - but might make the test case less confusing.
> > > In this case, the template parameters are not added to the variable name.
> > Why's that?
> > 
> > The parameters are part of the variable name for class and function templates - seems they'd be necessary/useful to disambiguate for variable templates too.
> > 
> > (though I do see that GCC (8.1) also doesn't seem to put template parameters on variable templates... )
> I did implement that in a previous patch (D44842), but it breaks LLDB's global symbol lookup.
Correction: It breaks global variable look up, not global symbol lookup.


Repository:
  rL LLVM

https://reviews.llvm.org/D52057





More information about the llvm-commits mailing list