Merges and also adding new bazel build mode

This commit is contained in:
Gennadiy Civil 2018-01-31 12:05:18 -05:00
parent e55fded0c8
commit e6ec8bc52f
3 changed files with 4 additions and 1 deletions

View File

@ -104,6 +104,7 @@ cc_library(
deps = select ({ deps = select ({
":has_absl": [ ":has_absl": [
"@com_google_absl//absl/types:optional", "@com_google_absl//absl/types:optional",
"@com_google_absl//absl/strings"
], ],
"//conditions:default": [], "//conditions:default": [],
} }

View File

@ -33,3 +33,4 @@ set -e
bazel build --curses=no //...:all bazel build --curses=no //...:all
bazel test --curses=no //...:all bazel test --curses=no //...:all
bazel test --curses=no //...:all --define absl=1

View File

@ -113,6 +113,7 @@
#if GTEST_HAS_ABSL #if GTEST_HAS_ABSL
#include "absl/types/optional.h" #include "absl/types/optional.h"
#include "absl/strings/string_view.h"
#endif // GTEST_HAS_ABSL #endif // GTEST_HAS_ABSL
namespace testing { namespace testing {
@ -629,7 +630,7 @@ inline void PrintTo(const ::std::wstring& s, ::std::ostream* os) {
#if GTEST_HAS_ABSL #if GTEST_HAS_ABSL
// Overload for absl::string_view. // Overload for absl::string_view.
inline void PrintTo(absl::string_view sp, ::std::ostream* os) { inline void PrintTo(absl::string_view sp, ::std::ostream* os) {
PrintTo(string(sp), os); PrintTo(::std::string(sp), os);
} }
#endif // GTEST_HAS_ABSL #endif // GTEST_HAS_ABSL