C++ Logo


Advanced search

Re: [std-proposals] creation function for std::vector

From: Jens Maurer <Jens.Maurer_at_[hidden]>
Date: Mon, 21 Mar 2022 09:28:58 +0100
On 21/03/2022 00.54, Tatsuya Yanagita wrote:
> Why is that better or worse than an additional constructor overload that
> takes a tag type, e.g. std::vector v(std::reserve, 42)
> ?
> I have no idea, though the non-member function may possibly be more compatible with autocomplete of editors than the constructor??

Such design considerations and the related rationale need to be part
of an eventual proposal presented to WG21.



Received on 2022-03-21 08:29:02