diff options
author | A. Unique TensorFlower <gardener@tensorflow.org> | 2018-08-27 11:01:09 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-08-27 11:12:14 -0700 |
commit | 8b05705ce58d264d09330531eea0c0701cc07ae2 (patch) | |
tree | b6ad2bacaa4b07938ade9d37b019e23e00eed569 /tensorflow/contrib/android | |
parent | bf0382b3d05c86485589c792ed914dfd043ff89b (diff) |
Replaced calls to tensorflow::StringPiece::ToString with std::string conversions.
That is, instances of sp.ToString() are replaced with string(sp).
This will allow tensorflow::StringPiece::ToString to be removed, which is necessary before it can be replaced with absl::string_view.
PiperOrigin-RevId: 210394878
Diffstat (limited to 'tensorflow/contrib/android')
-rw-r--r-- | tensorflow/contrib/android/asset_manager_filesystem.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tensorflow/contrib/android/asset_manager_filesystem.cc b/tensorflow/contrib/android/asset_manager_filesystem.cc index 513d519eab..d14b2126a0 100644 --- a/tensorflow/contrib/android/asset_manager_filesystem.cc +++ b/tensorflow/contrib/android/asset_manager_filesystem.cc @@ -28,7 +28,7 @@ string RemoveSuffix(const string& name, const string& suffix) { string output(name); StringPiece piece(output); str_util::ConsumeSuffix(&piece, suffix); - return piece.ToString(); + return string(piece); } // Closes the given AAsset when variable is destructed. @@ -231,7 +231,7 @@ string AssetManagerFileSystem::NormalizeDirectoryPath(const string& fname) { string AssetManagerFileSystem::RemoveAssetPrefix(const string& name) { StringPiece piece(name); str_util::ConsumePrefix(&piece, prefix_); - return piece.ToString(); + return string(piece); } bool AssetManagerFileSystem::DirectoryExists(const std::string& fname) { |