1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 07:47:37 +00:00

AK: Add formatters for Utf8View and Utf32View

Useful for debugging, especially in templated contexts.
This commit is contained in:
Timothy Flynn 2023-02-20 08:08:40 -05:00 committed by Andreas Kling
parent 385b880862
commit 0f20586346
5 changed files with 35 additions and 0 deletions

View file

@ -8,6 +8,7 @@
#include <AK/Assertions.h>
#include <AK/Checked.h>
#include <AK/Format.h>
#include <AK/Types.h>
namespace AK {
@ -119,6 +120,11 @@ private:
size_t m_length { 0 };
};
template<>
struct Formatter<Utf32View> : Formatter<StringView> {
ErrorOr<void> format(FormatBuilder&, Utf32View const&);
};
}
#if USING_AK_GLOBALLY