diff options
author | Gennadiy Civil <misterg@google.com> | 2019-04-11 19:59:46 (GMT) |
---|---|---|
committer | Gennadiy Civil <misterg@google.com> | 2019-04-11 19:59:46 (GMT) |
commit | adc8a88ff0c5c85413d37af20343faa6c197abad (patch) | |
tree | 0abfef6ee439ff1f6a7fa10ad9250ebf03de0830 | |
parent | ea9c49b9cd410cca4df39b376f7da7cddf2dcf6d (diff) | |
parent | 8e9297b503d6206b16389c756fde80f2cb2db6f4 (diff) | |
download | googletest-adc8a88ff0c5c85413d37af20343faa6c197abad.zip googletest-adc8a88ff0c5c85413d37af20343faa6c197abad.tar.gz googletest-adc8a88ff0c5c85413d37af20343faa6c197abad.tar.bz2 |
Merge pull request #2226 from davidben:msvc-5046
PiperOrigin-RevId: 243121568
-rw-r--r-- | googlemock/include/gmock/gmock-matchers.h | 11 | ||||
-rw-r--r-- | googletest/include/gtest/gtest-matchers.h | 11 |
2 files changed, 18 insertions, 4 deletions
diff --git a/googlemock/include/gmock/gmock-matchers.h b/googlemock/include/gmock/gmock-matchers.h index 3e4ee40..fcf8cf2 100644 --- a/googlemock/include/gmock/gmock-matchers.h +++ b/googlemock/include/gmock/gmock-matchers.h @@ -58,9 +58,16 @@ #include "gmock/internal/gmock-port.h" #include "gtest/gtest.h" +// MSVC warning C5046 is new as of VS2017 version 15.8. +#if defined(_MSC_VER) && _MSC_VER >= 1915 +#define GMOCK_MAYBE_5046_ 5046 +#else +#define GMOCK_MAYBE_5046_ +#endif + GTEST_DISABLE_MSC_WARNINGS_PUSH_( - 4251 5046 /* class A needs to have dll-interface to be used by clients of - class B */ + 4251 GMOCK_MAYBE_5046_ /* class A needs to have dll-interface to be used by + clients of class B */ /* Symbol involving type with internal linkage not defined */) namespace testing { diff --git a/googletest/include/gtest/gtest-matchers.h b/googletest/include/gtest/gtest-matchers.h index bf500fc..6e73ba1 100644 --- a/googletest/include/gtest/gtest-matchers.h +++ b/googletest/include/gtest/gtest-matchers.h @@ -47,9 +47,16 @@ #include "gtest/internal/gtest-internal.h" #include "gtest/internal/gtest-port.h" +// MSVC warning C5046 is new as of VS2017 version 15.8. +#if defined(_MSC_VER) && _MSC_VER >= 1915 +#define GTEST_MAYBE_5046_ 5046 +#else +#define GTEST_MAYBE_5046_ +#endif + GTEST_DISABLE_MSC_WARNINGS_PUSH_( - 4251 5046 /* class A needs to have dll-interface to be used by clients of - class B */ + 4251 GTEST_MAYBE_5046_ /* class A needs to have dll-interface to be used by + clients of class B */ /* Symbol involving type with internal linkage not defined */) namespace testing { |