git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109538
91177308-0d34-0410-b5e6-
96231b3b80d8
/// maps as well.
unsigned DwarfDebug::GetOrCreateSourceID(StringRef DirName, StringRef FileName){
unsigned DId;
- if (DirName.empty()) {
- llvm::sys::Path CWD = llvm::sys::Path::GetCurrentDirectory();
- DirName = StringRef(CWD.c_str(), CWD.size());
- }
+ assert (DirName.empty() == false && "Invalid directory name!");
StringMap<unsigned>::iterator DI = DirectoryIdMap.find(DirName);
if (DI != DirectoryIdMap.end()) {