forked from qt-creator/qt-creator
Utils: Make default constructor of SmallString constexpr
Change-Id: Ibf381c9f18de878b1f67e28498cd28270e9220c7 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -69,7 +69,7 @@ public:
|
||||
? sizeof(Internal::StringDataLayout<Size>) == Size + 1
|
||||
: sizeof(Internal::StringDataLayout<Size>) == Size + 2,
|
||||
"Size is wrong");
|
||||
|
||||
constexpr
|
||||
BasicSmallString() noexcept
|
||||
: m_data(Internal::StringDataLayout<Size>())
|
||||
{
|
||||
|
@@ -98,7 +98,7 @@ struct ALIGNAS_16 StringDataLayout {
|
||||
: ((MaximumShortStringDataAreaSize + 2) % 16) == 0,
|
||||
"Size + 1 must be dividable by 16 if under 64 and Size + 2 must be dividable by 16 if over 64!");
|
||||
|
||||
StringDataLayout() noexcept = default;
|
||||
constexpr StringDataLayout() noexcept = default;
|
||||
|
||||
constexpr StringDataLayout(const char *string,
|
||||
size_type size) noexcept
|
||||
|
Reference in New Issue
Block a user