aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/compiler/xla/text_literal_reader.cc
diff options
context:
space:
mode:
Diffstat (limited to 'tensorflow/compiler/xla/text_literal_reader.cc')
-rw-r--r--tensorflow/compiler/xla/text_literal_reader.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/tensorflow/compiler/xla/text_literal_reader.cc b/tensorflow/compiler/xla/text_literal_reader.cc
index 392ad84ef4..9835e3d803 100644
--- a/tensorflow/compiler/xla/text_literal_reader.cc
+++ b/tensorflow/compiler/xla/text_literal_reader.cc
@@ -95,9 +95,9 @@ StatusOr<std::unique_ptr<Literal>> TextLiteralReader::ReadAllLines() {
line.c_str());
}
float value;
- if (!absl::SimpleAtof(std::string(value_string).c_str(), &value)) {
+ if (!absl::SimpleAtof(absl::string_view(value_string), &value)) {
return InvalidArgument("could not parse value as float: \"%s\"",
- std::string(value_string).c_str());
+ string(value_string).c_str());
}
coordinates = absl::StrSplit(coordinates_string, ',');
coordinate_values.clear();