From 47a6f9b86ba56a6816c19cb7486ce1c7da872754 Mon Sep 17 00:00:00 2001 From: Seth Fowler Date: Tue, 26 Aug 2014 13:57:43 -0700 Subject: [PATCH] Bug 1057840 (Part 1) - Expand GCC version bounds for decltype scope operator workaround. r=waldo --- mfbt/tests/TestMaybe.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mfbt/tests/TestMaybe.cpp b/mfbt/tests/TestMaybe.cpp index 1c35e8b2a352..9315b09c684b 100644 --- a/mfbt/tests/TestMaybe.cpp +++ b/mfbt/tests/TestMaybe.cpp @@ -26,7 +26,7 @@ using mozilla::UniquePtr; // Work around a bug in Visual Studio 2010 that prevents expressions of the form // |decltype(foo)::type| from working. See here: // http://stackoverflow.com/questions/14330768/c11-compiler-error-when-using-decltypevar-followed-by-internal-type-of-var -// GCC 4.4 also appears to have a similar bug. +// GCC < 4.7 also has a similar bug. #if MOZ_IS_MSVC # if MOZ_MSVC_VERSION_AT_LEAST(11) # define DECLTYPE(EXPR) decltype(EXPR) @@ -35,7 +35,7 @@ using mozilla::UniquePtr; # define DECLTYPE(EXPR) Identity::type # endif #elif MOZ_IS_GCC -# if MOZ_GCC_VERSION_AT_LEAST(4,5,0) +# if MOZ_GCC_VERSION_AT_LEAST(4, 7, 0) # define DECLTYPE(EXPR) decltype(EXPR) # else template struct Identity { typedef T type; };