aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2015-01-12 21:45:44 +0000
committerJonathan Wakely <redi@gcc.gnu.org>2015-01-12 21:45:44 +0000
commit5e67acc9a07ef2af9a49bc7d34d82db593ebae6a (patch)
tree352898dc4a6294a2ddcdb8cd0d2f9a61f93de5af
parent3ae79bfd2627bbce13fe20c0fd53c0e48273c173 (diff)
downloadgcc-5e67acc9a07ef2af9a49bc7d34d82db593ebae6a.zip
gcc-5e67acc9a07ef2af9a49bc7d34d82db593ebae6a.tar.gz
gcc-5e67acc9a07ef2af9a49bc7d34d82db593ebae6a.tar.bz2
re PR libstdc++/64560 (building libstdc++ with -fno-rtti fails in new cxx11-shim-facets.cc file)
PR libstdc++/64560 * src/c++11/cxx11-shim_facets.cc (locale::facet::_M_sso_shim): Check for RTTI support. From-SVN: r219495
-rw-r--r--libstdc++-v3/ChangeLog6
-rw-r--r--libstdc++-v3/src/c++11/cxx11-shim_facets.cc2
2 files changed, 8 insertions, 0 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index cd666d1..55b2a24 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,9 @@
+2015-01-12 Jonathan Wakely <jwakely@redhat.com>
+
+ PR libstdc++/64560
+ * src/c++11/cxx11-shim_facets.cc (locale::facet::_M_sso_shim): Check
+ for RTTI support.
+
2015-01-10 Thomas Schwinge <thomas@codesourcery.com>
* doc/xml/manual/parallel_mode.xml: Update for libgomp being
diff --git a/libstdc++-v3/src/c++11/cxx11-shim_facets.cc b/libstdc++-v3/src/c++11/cxx11-shim_facets.cc
index 1a83e6c..56959b6 100644
--- a/libstdc++-v3/src/c++11/cxx11-shim_facets.cc
+++ b/libstdc++-v3/src/c++11/cxx11-shim_facets.cc
@@ -768,9 +768,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{
using namespace __facet_shims;
+#if __cpp_rtti
// If this is already a shim just use its underlying facet.
if (auto* p = dynamic_cast<const __shim*>(this))
return p->_M_get();
+#endif
if (which == &numpunct<char>::id)
return new numpunct_shim<char>{this};