Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/DefaultFileSystem.cpp

Issue 5163715573841920: Issue 768 - Switch from TR1 to C++11 (Closed)
Patch Set: Created July 11, 2014, 2:24 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/DefaultFileSystem.cpp
===================================================================
--- a/src/DefaultFileSystem.cpp
+++ b/src/DefaultFileSystem.cpp
@@ -61,27 +61,27 @@ namespace
// file paths as they are.
std::string NormalizePath(const std::string& path)
{
return path;
}
#endif
}
-std::tr1::shared_ptr<std::istream>
+std::shared_ptr<std::istream>
DefaultFileSystem::Read(const std::string& path) const
{
- std::tr1::shared_ptr<std::istream> result(new std::ifstream(NormalizePath(path).c_str()));
+ std::shared_ptr<std::istream> result(new std::ifstream(NormalizePath(path).c_str()));
if (result->fail())
throw RuntimeErrorWithErrno("Failed to open " + path);
return result;
}
void DefaultFileSystem::Write(const std::string& path,
- std::tr1::shared_ptr<std::istream> data)
+ std::shared_ptr<std::istream> data)
{
std::ofstream file(NormalizePath(path).c_str(), std::ios_base::out | std::ios_base::binary);
file << Utils::Slurp(*data);
}
void DefaultFileSystem::Move(const std::string& fromPath,
const std::string& toPath)
{

Powered by Google App Engine
This is Rietveld