[llvm] [DebugInfo][NFC] Fix PDB/Native/LinePrinter.h build warning -Wmicrosoft-unqualified-friend (PR #209715)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 15 03:02:05 PDT 2026
llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-debuginfo
Author: Wenju He (wenju-he)
<details>
<summary>Changes</summary>
Fix build warning on Windows, which is error under -Werror: unqualified friend declaration referring to type outside of the nearest enclosing namespace is a Microsoft extension; add a nested name specifier [-Wmicrosoft-unqualified-friend]
---
Full diff: https://github.com/llvm/llvm-project/pull/209715.diff
1 Files Affected:
- (modified) llvm/include/llvm/DebugInfo/PDB/Native/LinePrinter.h (+2-1)
``````````diff
diff --git a/llvm/include/llvm/DebugInfo/PDB/Native/LinePrinter.h b/llvm/include/llvm/DebugInfo/PDB/Native/LinePrinter.h
index 95293ba0818d5..bf77a3d19d9d4 100644
--- a/llvm/include/llvm/DebugInfo/PDB/Native/LinePrinter.h
+++ b/llvm/include/llvm/DebugInfo/PDB/Native/LinePrinter.h
@@ -47,9 +47,10 @@ namespace pdb {
class ClassLayout;
class PDBFile;
class SymbolGroup;
+class WithColor;
class LinePrinter {
- friend class WithColor;
+ friend class pdb::WithColor;
public:
LLVM_ABI LinePrinter(int Indent, bool UseColor, raw_ostream &Stream,
``````````
</details>
https://github.com/llvm/llvm-project/pull/209715
More information about the llvm-commits
mailing list