In the following definition, first argument of the new_object function should have “…” after class.
template<class T, class CtorArgs...> [[nodiscard]] T* new_object(CtorArgs&&... ctor_args);
Change the example as follows:
template<class T, class... CtorArgs> [[nodiscard]] T* new_object(CtorArgs&&... ctor_args)
In the following definition, first argument of the new_object function should have “…” after class. template<class T, class CtorArgs...> [[nodiscard]] T* new_object(CtorArgs&&... ctor_args);
Change the example as follows: template<class T, class... CtorArgs> [[nodiscard]] T* new_object(CtorArgs&&... ctor_args)
JP11