summaryrefslogtreecommitdiff
path: root/absl/strings
diff options
context:
space:
mode:
Diffstat (limited to 'absl/strings')
-rw-r--r--absl/strings/BUILD.bazel2
-rw-r--r--absl/strings/str_join.h1
-rw-r--r--absl/strings/string_view.h4
3 files changed, 5 insertions, 2 deletions
diff --git a/absl/strings/BUILD.bazel b/absl/strings/BUILD.bazel
index 3a5f1332..6caf8b97 100644
--- a/absl/strings/BUILD.bazel
+++ b/absl/strings/BUILD.bazel
@@ -19,6 +19,7 @@ load(
"ABSL_DEFAULT_COPTS",
"ABSL_TEST_COPTS",
"ABSL_EXCEPTIONS_FLAG",
+ "ABSL_EXCEPTIONS_FLAG_LINKOPTS",
)
package(
@@ -237,6 +238,7 @@ cc_test(
size = "small",
srcs = ["string_view_test.cc"],
copts = ABSL_TEST_COPTS + ABSL_EXCEPTIONS_FLAG,
+ linkopts = ABSL_EXCEPTIONS_FLAG_LINKOPTS,
visibility = ["//visibility:private"],
deps = [
":strings",
diff --git a/absl/strings/str_join.h b/absl/strings/str_join.h
index bd4d0e1d..b0680e83 100644
--- a/absl/strings/str_join.h
+++ b/absl/strings/str_join.h
@@ -52,6 +52,7 @@
#include <iterator>
#include <string>
#include <tuple>
+#include <type_traits>
#include <utility>
#include "absl/base/macros.h"
diff --git a/absl/strings/string_view.h b/absl/strings/string_view.h
index 1537a3f8..96101463 100644
--- a/absl/strings/string_view.h
+++ b/absl/strings/string_view.h
@@ -340,7 +340,7 @@ class string_view {
//
// Returns a "substring" of the `string_view` (at offset `pos` and length
// `n`) as another string_view. This function throws `std::out_of_bounds` if
- // `pos > size'.
+ // `pos > size`.
string_view substr(size_type pos, size_type n = npos) const {
if (ABSL_PREDICT_FALSE(pos > length_))
base_internal::ThrowStdOutOfRange("absl::string_view::substr");
@@ -351,7 +351,7 @@ class string_view {
// string_view::compare()
//
// Performs a lexicographical comparison between the `string_view` and
- // another `absl::string_view), returning -1 if `this` is less than, 0 if
+ // another `absl::string_view`, returning -1 if `this` is less than, 0 if
// `this` is equal to, and 1 if `this` is greater than the passed std::string
// view. Note that in the case of data equality, a further comparison is made
// on the respective sizes of the two `string_view`s to determine which is