diff options
author | Ahmed Charles <ahmedcharles@gmail.com> | 2014-03-07 19:33:25 +0000 |
---|---|---|
committer | Ahmed Charles <ahmedcharles@gmail.com> | 2014-03-07 19:33:25 +0000 |
commit | 9a16beb8bc580212df519aa488242a94e53741d8 (patch) | |
tree | 569f8fb251291e9aaacc0ddb6d509a9561ddc264 /clang/lib/Tooling/JSONCompilationDatabase.cpp | |
parent | 9cbd3c628cfdcb7ba2f372b57db317df2a271ebb (diff) | |
download | bcm5719-llvm-9a16beb8bc580212df519aa488242a94e53741d8.tar.gz bcm5719-llvm-9a16beb8bc580212df519aa488242a94e53741d8.zip |
Change OwningPtr::take() to OwningPtr::release().
This is a precursor to moving to std::unique_ptr.
llvm-svn: 203275
Diffstat (limited to 'clang/lib/Tooling/JSONCompilationDatabase.cpp')
-rw-r--r-- | clang/lib/Tooling/JSONCompilationDatabase.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/clang/lib/Tooling/JSONCompilationDatabase.cpp b/clang/lib/Tooling/JSONCompilationDatabase.cpp index dad4600798b..232c329de23 100644 --- a/clang/lib/Tooling/JSONCompilationDatabase.cpp +++ b/clang/lib/Tooling/JSONCompilationDatabase.cpp @@ -126,7 +126,7 @@ class JSONCompilationDatabasePlugin : public CompilationDatabasePlugin { JSONCompilationDatabase::loadFromFile(JSONDatabasePath, ErrorMessage)); if (!Database) return NULL; - return Database.take(); + return Database.release(); } }; @@ -152,10 +152,10 @@ JSONCompilationDatabase::loadFromFile(StringRef FilePath, return NULL; } OwningPtr<JSONCompilationDatabase> Database( - new JSONCompilationDatabase(DatabaseBuffer.take())); + new JSONCompilationDatabase(DatabaseBuffer.release())); if (!Database->parse(ErrorMessage)) return NULL; - return Database.take(); + return Database.release(); } JSONCompilationDatabase * @@ -164,10 +164,10 @@ JSONCompilationDatabase::loadFromBuffer(StringRef DatabaseString, OwningPtr<llvm::MemoryBuffer> DatabaseBuffer( llvm::MemoryBuffer::getMemBuffer(DatabaseString)); OwningPtr<JSONCompilationDatabase> Database( - new JSONCompilationDatabase(DatabaseBuffer.take())); + new JSONCompilationDatabase(DatabaseBuffer.release())); if (!Database->parse(ErrorMessage)) return NULL; - return Database.take(); + return Database.release(); } std::vector<CompileCommand> |