diff options
Diffstat (limited to 'clang/lib/Serialization/GlobalModuleIndex.cpp')
-rw-r--r-- | clang/lib/Serialization/GlobalModuleIndex.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/clang/lib/Serialization/GlobalModuleIndex.cpp b/clang/lib/Serialization/GlobalModuleIndex.cpp index e46cb97b9f3..5cd3ad55757 100644 --- a/clang/lib/Serialization/GlobalModuleIndex.cpp +++ b/clang/lib/Serialization/GlobalModuleIndex.cpp @@ -228,7 +228,7 @@ GlobalModuleIndex::readIndex(StringRef Path) { IndexPath += Path; llvm::sys::path::append(IndexPath, IndexFileName); - llvm::OwningPtr<llvm::MemoryBuffer> Buffer; + std::unique_ptr<llvm::MemoryBuffer> Buffer; if (llvm::MemoryBuffer::getFile(IndexPath.c_str(), Buffer) != llvm::errc::success) return std::make_pair((GlobalModuleIndex *)0, EC_NotFound); @@ -469,7 +469,7 @@ namespace { bool GlobalModuleIndexBuilder::loadModuleFile(const FileEntry *File) { // Open the module file. - OwningPtr<llvm::MemoryBuffer> Buffer; + std::unique_ptr<llvm::MemoryBuffer> Buffer; std::string ErrorStr; Buffer.reset(FileMgr.getBufferForFile(File, &ErrorStr, /*isVolatile=*/true)); if (!Buffer) { @@ -593,10 +593,10 @@ bool GlobalModuleIndexBuilder::loadModuleFile(const FileEntry *File) { if (State == ASTBlock && Code == IDENTIFIER_TABLE && Record[0] > 0) { typedef OnDiskChainedHashTable<InterestingASTIdentifierLookupTrait> InterestingIdentifierTable; - llvm::OwningPtr<InterestingIdentifierTable> - Table(InterestingIdentifierTable::Create( - (const unsigned char *)Blob.data() + Record[0], - (const unsigned char *)Blob.data())); + std::unique_ptr<InterestingIdentifierTable> Table( + InterestingIdentifierTable::Create( + (const unsigned char *)Blob.data() + Record[0], + (const unsigned char *)Blob.data())); for (InterestingIdentifierTable::data_iterator D = Table->data_begin(), DEnd = Table->data_end(); D != DEnd; ++D) { |