Skip to content

Commit dca0825

Browse files
author
git apple-llvm automerger
committed
Merge commit 'cf66110ca9e9' from swift/release/6.2 into stable/20240723
2 parents e92ed8f + cf66110 commit dca0825

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

clang/lib/CodeGen/CGDebugInfo.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3119,6 +3119,9 @@ llvm::DIModule *CGDebugInfo::getOrCreateModuleRef(ASTSourceDescriptor Mod,
31193119
std::string Remapped = remapDIPath(Path);
31203120
StringRef Relative(Remapped);
31213121
StringRef CompDir = TheCU->getDirectory();
3122+
if (CompDir.empty())
3123+
return Remapped;
3124+
31223125
if (Relative.consume_front(CompDir))
31233126
Relative.consume_front(llvm::sys::path::get_separator());
31243127

0 commit comments

Comments
 (0)