diff options
author | Gennadiy Civil <gennadiycivil@users.noreply.github.com> | 2018-11-01 14:45:47 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-01 14:45:47 (GMT) |
commit | 9636db6b2b9bd15b10f50473436451005a656f25 (patch) | |
tree | 3aa25106d0d18eb891ff0376ed3ccd50789888db /googletest | |
parent | 4ea629d31d4a0b3cab98b0b237e666c265dae895 (diff) | |
parent | 88c15b5fdeccfe597998c1cbf73d5be02a9ce728 (diff) | |
download | googletest-9636db6b2b9bd15b10f50473436451005a656f25.zip googletest-9636db6b2b9bd15b10f50473436451005a656f25.tar.gz googletest-9636db6b2b9bd15b10f50473436451005a656f25.tar.bz2 |
Merge branch 'master' into makefixrefs/pull/1950/head
Diffstat (limited to 'googletest')
-rw-r--r-- | googletest/include/gtest/internal/gtest-internal.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/googletest/include/gtest/internal/gtest-internal.h b/googletest/include/gtest/internal/gtest-internal.h index f62725a..217ee79 100644 --- a/googletest/include/gtest/internal/gtest-internal.h +++ b/googletest/include/gtest/internal/gtest-internal.h @@ -1423,4 +1423,19 @@ class FlatTuple test_case_name, test_name)>); \ void GTEST_TEST_CLASS_NAME_(test_case_name, test_name)::TestBody() +// Internal Macro to mark an API deprecated, for googletest usage only +// Usage: class GTEST_INTERNAL_DEPRECATED(message) MyClass or +// GTEST_INTERNAL_DEPRECATED(message) <return_type> myFunction(); Every usage of +// a deprecated entity will trigger a warning when compiled with +// `-Wdeprecated-declarations` option (clang, gcc, any __GNUC__ compiler). +// For msvc /W3 option will need to be used +// Note that for 'other' compilers this macro evaluates to nothing to prevent +// compilations errors. +#if defined(_MSC_VER) +#define GTEST_INTERNAL_DEPRECATED(message) __declspec(deprecated(message)) +#elif defined(__GNUC__) +#define GTEST_INTERNAL_DEPRECATED(message) __attribute__((deprecated(message))) +#else +#define GTEST_INTERNAL_DEPRECATED(message) +#endif #endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_INTERNAL_H_ |