[patch] libstdc++/65630 add exports for operator+() with std::__cxx11::basic_string
Jonathan Wakely
jwakely@redhat.com
Mon Mar 30 17:59:00 GMT 2015
In the library we instantiate these functions:
template S operator+(const C*, const S&);
template S operator+(C, const S&);
template S operator+(const S&, const S&);
We have a Fedora bug report for a package which uses
-fno-implicit-templates and then expects to find these instantations
in the library. I didn't add the linker script exports for the new
versions of the functions, so they were not usable outside the
library, causing the package to fail to link when using the new
std::string ABI.
Since we've always exported these for the old std::string I think we
should continue to do so for the new std::string as well.
When we're in stage 1 I think we should also add 'extern template'
declarations for these instantiations, so that we actually tell the
compiler they exist and everyone can benefit from them, not only
broken packages (mis)using -fno-implicit-templates.
Tested x86_64-linux, committed to trunk.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.txt
Type: text/x-patch
Size: 3553 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20150330/792d7087/attachment.bin>
More information about the Libstdc++
mailing list