mirror of
https://github.com/Gericom/teak-llvm.git
synced 2025-06-20 20:15:49 -04:00

I was going through some of the old bugs and came across PR21069 which I was able to reproduce. The issue is that we match the regex `^foo` against the `DW_AT_name` in the DWARF, which for our anonymous function is indeed `foo`. However, when we get the function name from the symbol context, the result is `(anonymous namespace)::foo()`. This throws off completions, which assumes that it's appending to whatever is already present on the input, resulting in a bogus `b fooonymous\ namespace)::foo()`. Bug report: https://llvm.org/PR21069 Differential revision: https://reviews.llvm.org/D65498 llvm-svn: 367455
25 lines
382 B
C++
25 lines
382 B
C++
class Foo
|
|
{
|
|
public:
|
|
int Bar(int x, int y)
|
|
{
|
|
return x + y;
|
|
}
|
|
};
|
|
|
|
namespace { int Quux (void) { return 0; } }
|
|
|
|
struct Container { int MemberVar; };
|
|
|
|
int main()
|
|
{
|
|
Foo fooo;
|
|
Foo *ptr_fooo = &fooo;
|
|
fooo.Bar(1, 2);
|
|
|
|
Container container;
|
|
Container *ptr_container = &container;
|
|
int q = Quux();
|
|
return container.MemberVar = 3; // Break here
|
|
}
|