- Fix the assertion hit when generating code for global variable initializer of
_BitInt(1) type.
(`#62207 <https://github.com/llvm/llvm-project/issues/62207>`_)
+- Fix lambdas and other anonymous function names not respecting ``-fdebug-prefix-map``
+ (`#62192 <https://github.com/llvm/llvm-project/issues/62192>`_)
Bug Fixes to Compiler Builtins
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
llvm_unreachable("unknown module kind");
}
-void NamedDecl::printName(raw_ostream &OS, const PrintingPolicy&) const {
- OS << Name;
+void NamedDecl::printName(raw_ostream &OS, const PrintingPolicy &Policy) const {
+ Name.print(OS, Policy);
}
void NamedDecl::printName(raw_ostream &OS) const {
Policy.adjustForCPlusPlus();
if (const RecordType *ClassRec = ClassType->getAs<RecordType>()) {
- OS << *ClassRec->getDecl();
+ ClassRec->getDecl()->printName(OS, Policy);
return;
}
if (Policy.SuppressTemplateArgsInCXXConstructors) {
if (auto *InjTy = ClassType->getAs<InjectedClassNameType>()) {
- OS << *InjTy->getDecl();
+ InjTy->getDecl()->printName(OS, Policy);
return;
}
}
--- /dev/null
+// RUN: %clang_cc1 -debug-info-kind=standalone -fdebug-prefix-map=%p=./UNLIKELY_PATH/empty -S %s -emit-llvm -o - | FileCheck %s
+
+struct alignas(64) an {
+ struct {
+ unsigned char x{0};
+ } arr[64];
+};
+
+struct an *pan = new an;
+
+// CHECK: !DISubprogram(name: "(unnamed struct at ./UNLIKELY_PATH/empty{{/|\\\\}}{{.*}}",