AK: Ignore "alternative" formatting of StringView instead of crashing

Jakt implements this in a different way, but it's a noop for
StringViews anyway.
This commit is contained in:
Ali Mohammad Pur 2022-12-10 19:30:34 +03:30 committed by Ali Mohammad Pur
parent 1cc8cdcd23
commit ff038f306a
Notes: sideshowbarker 2024-07-17 03:26:01 +09:00

View file

@ -669,8 +669,6 @@ ErrorOr<void> Formatter<StringView>::format(FormatBuilder& builder, StringView v
{
if (m_sign_mode != FormatBuilder::SignMode::Default)
VERIFY_NOT_REACHED();
if (m_alternative_form)
VERIFY_NOT_REACHED();
if (m_zero_pad)
VERIFY_NOT_REACHED();
if (m_mode != Mode::Default && m_mode != Mode::String && m_mode != Mode::Character && m_mode != Mode::HexDump)