Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1983)

Unified Diff: base/template_util.h

Issue 2612933003: Enable type_traits fallback for all < gcc 5.0 releases. (Closed)
Patch Set: comment tweak Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/template_util.h
diff --git a/base/template_util.h b/base/template_util.h
index 80a24d1722e2c466e31d2e09f483a4a73a45e90b..84e2563e34962819b4a8cca03f1a14af1953c460 100644
--- a/base/template_util.h
+++ b/base/template_util.h
@@ -24,13 +24,11 @@
#endif
// Some versions of libstdc++ have partial support for type_traits, but misses
-// a smaller subset while removing some of the older non-standard stuff.
-#define CR_GLIBCXX_4_8_4 20141219
-#define CR_GLIBCXX_4_9_2 20150426
+// a smaller subset while removing some of the older non-standard stuff. Assume
+// that all versions below 5.0 fall in this category, along with one 5.0
+// experimental release.
#define CR_GLIBCXX_5_0_0 20150123
-#if defined(__GLIBCXX__) && \
- (__GLIBCXX__ == CR_GLIBCXX_4_8_4 || __GLIBCXX__ == CR_GLIBCXX_4_9_2 || \
- __GLIBCXX__ == CR_GLIBCXX_5_0_0)
+#if _GNUC_VER < 500 || (defined(__GLIBCXX__) && __GLIBCXX__ == CR_GLIBCXX_5_0_0)
Mostyn Bramley-Moore 2017/01/05 10:53:54 Where is _GNUC_VER defined? It doesn't appear to
sof 2017/01/05 10:57:38 It's used below in this file, so I assume it is we
Mostyn Bramley-Moore 2017/01/05 12:26:32 It looks like _GNUC_VER is a libcxx macro, and sin
sof 2017/01/05 12:35:28 It's been subsequently updated to only rely on __G
#define CR_USE_FALLBACKS_FOR_OLD_EXPERIMENTAL_GLIBCXX
#endif
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698