olegantonyan / googletest

Automatically exported from code.google.com/p/googletest. Added qmake build
BSD 3-Clause "New" or "Revised" License
1 stars 0 forks source link

need to workaround a gcc bug when RTTI is disabled #153

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
gcc 4.0.0 (at least on Mac) has a bug that prevents tr1/functional
from compiling when RTTI is disabled (i.e. when -fno-rtti is
specified).

gtest doesn't use tr1/functional.  However, its Combine() function
(for value-parameterized tests) use tr1/tuple, whose implementation
happens to pull in tr1/functional (that's how gcc implements it).

Therefore, when GTEST_HAS_RTTI is 0, we should set GTEST_HAS_TR1_TUPLE
to 0 by default, in order to prevent gtest from including tr1/tuple.

Q: gmock requires tr1/tuple.  Does this mean gmock doesn't work with
gcc when RTTI is disabled?  Need to investigate whether the problem is
Mac specific...

Original issue reported on code.google.com by shiq...@gmail.com on 3 Jun 2009 at 10:17

GoogleCodeExporter commented 9 years ago

Original comment by zhanyong...@gmail.com on 3 Jun 2009 at 10:18

GoogleCodeExporter commented 9 years ago

Original comment by zhanyong...@gmail.com on 3 Jun 2009 at 10:18

GoogleCodeExporter commented 9 years ago
Fixed in r265.

Original comment by zhanyong...@gmail.com on 11 Jun 2009 at 3:40