C++ Logo

STD-DISCUSSION

Advanced search

Subject: Re: extremely long compile time with large number of string literals
From: Thiago Macieira (thiago_at_[hidden])
Date: 2020-07-13 13:01:25


On Monday, 13 July 2020 10:56:36 PDT Andrey Semashev via Std-Discussion wrote:
> > Ideally a constexpr string object using constexpr operator new could do
> > that, but such a thing does not exist in C++ yet and definitely did not
> > for C++11 or C++14.
> >
> > The best you can get until is to benefit from the Small String
> > Optimisation.
> Using string_view instead of string would be better yet.

Indeed, but that's also C++17.

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
   Software Architect - Intel System Software Products

STD-DISCUSSION list run by std-discussion-owner@lists.isocpp.org

Older Archives on Google Groups