metall icon indicating copy to clipboard operation
metall copied to clipboard

Do not rely on implementation details of `boost::interprocess`

Open liss-h opened this issue 1 year ago • 4 comments

In this header for instance https://github.com/LLNL/metall/blob/master/include/metall/detail/array_construct.hpp there is a using declaration for array_construct out of the ipcdetail namespace of boost::interprocess. (There might be other places like this)

This namespace is an implementation detail namespace in boost which you are not supposed to access. This causes issues because in recent boost releases (>=1.85) they removed that function, which means that metall does no longer compile with those releases.

liss-h avatar Oct 02 '24 13:10 liss-h

Thanks for the report, Liss! Yeah, I know it's not a public API, and it is better to avoid using it generally. But, unfortunately, the object construction logic is complicated and requires deep C++ knowledge. That's why I rely on some code in the details namespace. Boost changes its public API frequently anyway, so I believe using a little non-public API is reasonable as long as we keep testing the new boost versions (I should update our CI script more frequently to keep up with boost...).

KIwabuchi avatar Oct 04 '24 03:10 KIwabuchi

I was able to fix the bug you found: https://github.com/LLNL/metall/pull/333

I'll merge the PR once I update some documentation.

KIwabuchi avatar Oct 04 '24 03:10 KIwabuchi

I have merged https://github.com/LLNL/metall/pull/333 to the develop branch.

KIwabuchi avatar Oct 04 '24 03:10 KIwabuchi

(I reopened this issue as I accidentally closed it..)

KIwabuchi avatar Oct 04 '24 04:10 KIwabuchi

Thanks, can be closed

liss-h avatar Oct 08 '24 12:10 liss-h