diff options
author | A. Unique TensorFlower <gardener@tensorflow.org> | 2018-08-28 09:07:14 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-08-28 09:11:17 -0700 |
commit | f8f5bbe006bc98e98fd939898ceff08dbaace34f (patch) | |
tree | 0ce731cb888e678790f69923788decfb58a7a9cb /tensorflow/core/platform | |
parent | 2cb954e5441605c8668d2aecbf12e324a07b3c89 (diff) |
Removed ToString method from tensorflow::StringPiece.
This will make it easier to replace tensorflow::StringPiece with absl::string_view, as absl::string_view does not contain a ToString method.
PiperOrigin-RevId: 210550029
Diffstat (limited to 'tensorflow/core/platform')
-rw-r--r-- | tensorflow/core/platform/s3/s3_file_system.cc | 4 | ||||
-rw-r--r-- | tensorflow/core/platform/windows/windows_file_system.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/tensorflow/core/platform/s3/s3_file_system.cc b/tensorflow/core/platform/s3/s3_file_system.cc index 462113f9bb..ce0f6cd741 100644 --- a/tensorflow/core/platform/s3/s3_file_system.cc +++ b/tensorflow/core/platform/s3/s3_file_system.cc @@ -150,13 +150,13 @@ Status ParseS3Path(const string& fname, bool empty_object_ok, string* bucket, return errors::InvalidArgument("S3 path doesn't start with 's3://': ", fname); } - *bucket = bucketp.ToString(); + *bucket = string(bucketp); if (bucket->empty() || *bucket == ".") { return errors::InvalidArgument("S3 path doesn't contain a bucket name: ", fname); } str_util::ConsumePrefix(&objectp, "/"); - *object = objectp.ToString(); + *object = string(objectp); if (!empty_object_ok && object->empty()) { return errors::InvalidArgument("S3 path doesn't contain an object name: ", fname); diff --git a/tensorflow/core/platform/windows/windows_file_system.h b/tensorflow/core/platform/windows/windows_file_system.h index 6b04720c68..1f4c535f24 100644 --- a/tensorflow/core/platform/windows/windows_file_system.h +++ b/tensorflow/core/platform/windows/windows_file_system.h @@ -71,7 +71,7 @@ class LocalWinFileSystem : public WindowsFileSystem { string TranslateName(const string& name) const override { StringPiece scheme, host, path; io::ParseURI(name, &scheme, &host, &path); - return path.ToString(); + return string(path); } }; |