We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 497ae4e + 29b579e commit 0464fd3Copy full SHA for 0464fd3
lib/ClangImporter/ImportDecl.cpp
@@ -8193,9 +8193,13 @@ ClangImporter::Implementation::importDeclForDeclContext(
8193
if (!contextDeclsWarnedAbout.insert(contextDecl).second)
8194
return nullptr;
8195
8196
- auto getDeclName = [](const clang::Decl *D) -> StringRef {
8197
- if (auto ND = dyn_cast<clang::NamedDecl>(D))
8198
- return ND->getName();
+ auto getDeclName = [](const clang::Decl *D) -> std::string {
+ if (auto ND = dyn_cast<clang::NamedDecl>(D)) {
+ std::string name;
8199
+ llvm::raw_string_ostream os(name);
8200
+ ND->printName(os);
8201
+ return name;
8202
+ }
8203
return "<anonymous>";
8204
};
8205
0 commit comments