Use windows baskslash on anonymous tag locations if using MSVCFormatting and it's...
authorZequan Wu <zequanwu@google.com>
Wed, 17 May 2023 21:06:42 +0000 (17:06 -0400)
committerZequan Wu <zequanwu@google.com>
Fri, 19 May 2023 12:44:12 +0000 (08:44 -0400)
commit75993812d5c1f269b781c34987748f2a792a579d
treec898bad821659a121a328cf811927c7ac738f38b
parentcb16b33a03aff70b2499c3452f2f817f3f92d20d
Use windows baskslash on anonymous tag locations if using MSVCFormatting and it's not absolute path.

This fixes a nondeterminism on debug info when building on windows natively vs
cross building to windows.

[1] https://github.com/llvm/llvm-project/blob/llvmorg-17-init/clang/lib/Lex/HeaderSearch.cpp#L465

Differential Revision: https://reviews.llvm.org/D150817
clang/lib/AST/TypePrinter.cpp
clang/test/CodeGen/Inputs/debug-info-slash.cpp [new file with mode: 0644]
clang/test/CodeGen/Inputs/debug-info-slash.h [new file with mode: 0644]
clang/test/CodeGen/debug-info-slash.test [new file with mode: 0644]