mirror of
https://github.com/intel/llvm.git
synced 2026-01-31 16:29:50 +08:00
remove the SourceManager:: and FullSourceLoc::getFileEntryForLoc methods.
llvm-svn: 62496
This commit is contained in:
@@ -283,7 +283,6 @@ public:
|
||||
const llvm::MemoryBuffer* getBuffer() const;
|
||||
|
||||
const char* getSourceName() const;
|
||||
const FileEntry* getFileEntryForLoc() const;
|
||||
|
||||
bool isInSystemHeader() const;
|
||||
|
||||
|
||||
@@ -412,12 +412,6 @@ public:
|
||||
return FileIDs[ChunkID-1].getContentCache();
|
||||
}
|
||||
|
||||
/// getFileEntryForLoc - Return the FileEntry record for the spelling loc of
|
||||
/// the specified SourceLocation, if one exists.
|
||||
const FileEntry* getFileEntryForLoc(SourceLocation Loc) const {
|
||||
return getContentCacheForLoc(Loc)->Entry;
|
||||
}
|
||||
|
||||
/// getFileEntryForID - Returns the FileEntry record for the provided FileID.
|
||||
const FileEntry *getFileEntryForID(FileID FID) const {
|
||||
return getContentCache(FID)->Entry;
|
||||
|
||||
@@ -94,11 +94,6 @@ const char* FullSourceLoc::getSourceName() const {
|
||||
return SrcMgr->getSourceName(*this);
|
||||
}
|
||||
|
||||
const FileEntry* FullSourceLoc::getFileEntryForLoc() const {
|
||||
assert(isValid());
|
||||
return SrcMgr->getFileEntryForLoc(*this);
|
||||
}
|
||||
|
||||
bool FullSourceLoc::isInSystemHeader() const {
|
||||
assert(isValid());
|
||||
return SrcMgr->isInSystemHeader(*this);
|
||||
|
||||
@@ -51,7 +51,7 @@ llvm::DICompileUnit CGDebugInfo::getOrCreateCompileUnit(SourceLocation Loc) {
|
||||
return llvm::DICompileUnit();
|
||||
|
||||
SourceManager &SM = M->getContext().getSourceManager();
|
||||
const FileEntry *FE = SM.getFileEntryForLoc(Loc);
|
||||
const FileEntry *FE = SM.getFileEntryForID(SM.getCanonicalFileID(Loc));
|
||||
if (FE == 0) return llvm::DICompileUnit();
|
||||
|
||||
// See if this compile unit has been used before.
|
||||
|
||||
Reference in New Issue
Block a user