From bff26e4fa14a90196c0c05f2d1d98ffc501fc9fd Mon Sep 17 00:00:00 2001 From: Richard Thomson Date: Thu, 15 Feb 2024 09:32:22 -0700 Subject: [PATCH] Correct in place factory example code The example code as given won't work without const qualifiers on the pointer arguments. --- doc/in_place_factory.qbk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/in_place_factory.qbk b/doc/in_place_factory.qbk index e69f3d667..42a079524 100644 --- a/doc/in_place_factory.qbk +++ b/doc/in_place_factory.qbk @@ -256,13 +256,13 @@ struct C ~C() { delete contained_ ; } template - void construct ( InPlaceFactory const& aFactory, boost::__in_place_factory_base__* ) + void construct ( InPlaceFactory const& aFactory, const boost::__in_place_factory_base__* ) { aFactory.template apply(contained_); } template - void construct ( TypedInPlaceFactory const& aFactory, boost::__typed_in_place_factory_base__* ) + void construct ( TypedInPlaceFactory const& aFactory, const boost::__typed_in_place_factory_base__* ) { aFactory.apply(contained_); }