Opened 13 years ago
Closed 13 years ago
#3261 closed Bugs (fixed)
Can't export derived class with a data member of type std::string
Reported by: | Owned by: | Matthias Troyer | |
---|---|---|---|
Milestone: | Boost 1.40.0 | Component: | mpi |
Version: | Boost 1.39.0 | Severity: | Problem |
Keywords: | Cc: |
Description
The attached file shows that calling BOOST_CLASS_EXPORT on a derived class that contains a data member of type std::string will fail at compilation.
Adding
namespace boost { namespace mpi { template<> struct is_mpi_datatype<std::string> : public mpl::true_ {}; } }
will make it compile and run.
Attachments (1)
Change History (5)
by , 13 years ago
comment:1 by , 13 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:2 by , 13 years ago
comment:3 by , 13 years ago
Bug is fixed and the patch will be committed to trunk and release once all regression tests are confirmed to work again
comment:4 by , 13 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Note:
See TracTickets
for help on using tickets.
The bug is confirmed and is caused by Boost.Serialization treating std::string and std::wstring as fundamental types to be handled directly by the archive. I'm thinking about how best to solve this for the skeleton&content mechanism, which is the issue here.