mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 06:17:34 +00:00
AK: Add formatters for Utf8View and Utf32View
Useful for debugging, especially in templated contexts.
This commit is contained in:
parent
385b880862
commit
0f20586346
5 changed files with 35 additions and 0 deletions
|
@ -8,6 +8,7 @@
|
|||
#pragma once
|
||||
|
||||
#include <AK/DeprecatedString.h>
|
||||
#include <AK/Format.h>
|
||||
#include <AK/StringView.h>
|
||||
#include <AK/Types.h>
|
||||
|
||||
|
@ -164,6 +165,11 @@ private:
|
|||
Utf8CodePointIterator m_it;
|
||||
};
|
||||
|
||||
template<>
|
||||
struct Formatter<Utf8View> : Formatter<StringView> {
|
||||
ErrorOr<void> format(FormatBuilder&, Utf8View const&);
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#if USING_AK_GLOBALLY
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue