Fix -Wsubobject-linkage warning (#6243)

* Fix -Wsubobject-linkage warning

Having tk::spline header-only implementation included from
SmallAreaInfillFlowCompensator.hpp makes
SmallAreaInfillFlowCompensator::flowModel have separate (albeit the
same) implementation in each translation unit.

In order to fix this issue, SmallAreaInfillFlowCompensator::flowModel
converted to opaque 'pimpl'

* spline: remove anonymous namespace

Remove outer anonymous namespace from splice.h to make
forward declaration for tk::spline possible.
This commit is contained in:
Dima Buzdyk
2024-08-04 08:48:24 +06:00
committed by GitHub
parent 9ff0e9335f
commit e6ed93f0c6
3 changed files with 9 additions and 21 deletions

View File

@@ -46,11 +46,6 @@
#pragma GCC diagnostic ignored "-Wunused-function"
#endif
// unnamed namespace only because the implementation is in this
// header file and we don't want to export symbols to the obj files
namespace
{
namespace tk
{
@@ -942,8 +937,6 @@ std::vector<double> solve_cubic(double a, double b, double c, double d,
} // namespace tk
} // namespace
#if !defined(_MSC_VER)
#pragma GCC diagnostic pop
#endif