Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
yangql
googletest
Commits
cdb24f86
Commit
cdb24f86
authored
May 02, 2012
by
vladlosev
Browse files
Teach gtest to autodetect rtti support with clang (by Nico Weber).
parent
9a56024c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
include/gtest/internal/gtest-port.h
include/gtest/internal/gtest-port.h
+7
-0
No files found.
include/gtest/internal/gtest-port.h
View file @
cdb24f86
...
@@ -391,6 +391,13 @@
...
@@ -391,6 +391,13 @@
# define GTEST_HAS_RTTI 0
# define GTEST_HAS_RTTI 0
# endif // __GXX_RTTI
# endif // __GXX_RTTI
// Clang defines __GXX_RTTI starting with version 3.0, but its manual recommends
// using has_feature instead. has_feature(cxx_rtti) is supported since 2.7, the
// first version with C++ support.
# elif defined(__clang__)
# define GTEST_HAS_RTTI __has_feature(cxx_rtti)
// Starting with version 9.0 IBM Visual Age defines __RTTI_ALL__ to 1 if
// Starting with version 9.0 IBM Visual Age defines __RTTI_ALL__ to 1 if
// both the typeid and dynamic_cast features are present.
// both the typeid and dynamic_cast features are present.
# elif defined(__IBMCPP__) && (__IBMCPP__ >= 900)
# elif defined(__IBMCPP__) && (__IBMCPP__ >= 900)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment