summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibTTF/Cmap.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Userland/Libraries/LibTTF/Cmap.cpp')
-rw-r--r--Userland/Libraries/LibTTF/Cmap.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/Userland/Libraries/LibTTF/Cmap.cpp b/Userland/Libraries/LibTTF/Cmap.cpp
index ce651e5385..5a4993fbaf 100644
--- a/Userland/Libraries/LibTTF/Cmap.cpp
+++ b/Userland/Libraries/LibTTF/Cmap.cpp
@@ -45,7 +45,7 @@ Cmap::Subtable::Platform Cmap::Subtable::platform_id() const
case 4:
return Platform::Custom;
default:
- ASSERT_NOT_REACHED();
+ VERIFY_NOT_REACHED();
}
}
@@ -71,7 +71,7 @@ Cmap::Subtable::Format Cmap::Subtable::format() const
case 14:
return Format::UnicodeVariationSequences;
default:
- ASSERT_NOT_REACHED();
+ VERIFY_NOT_REACHED();
}
}
@@ -89,7 +89,7 @@ Optional<Cmap::Subtable> Cmap::subtable(u32 index) const
u16 platform_id = be_u16(m_slice.offset_pointer(record_offset));
u16 encoding_id = be_u16(m_slice.offset_pointer(record_offset + (u32)Offsets::EncodingRecord_EncodingID));
u32 subtable_offset = be_u32(m_slice.offset_pointer(record_offset + (u32)Offsets::EncodingRecord_Offset));
- ASSERT(subtable_offset < m_slice.size());
+ VERIFY(subtable_offset < m_slice.size());
auto subtable_slice = ReadonlyBytes(m_slice.offset_pointer(subtable_offset), m_slice.size() - subtable_offset);
return Subtable(subtable_slice, platform_id, encoding_id);
}
@@ -128,7 +128,7 @@ u32 Cmap::Subtable::glyph_id_for_codepoint_table_4(u32 codepoint) const
return (codepoint + delta) & 0xffff;
}
u32 glyph_offset = (u32)Table4Offsets::GlyphOffsetConstBase + segcount_x2 * 3 + offset + range + (codepoint - start_codepoint) * 2;
- ASSERT(glyph_offset + 2 <= m_slice.size());
+ VERIFY(glyph_offset + 2 <= m_slice.size());
return (be_u16(m_slice.offset_pointer(glyph_offset)) + delta) & 0xffff;
}
return 0;
@@ -137,7 +137,7 @@ u32 Cmap::Subtable::glyph_id_for_codepoint_table_4(u32 codepoint) const
u32 Cmap::Subtable::glyph_id_for_codepoint_table_12(u32 codepoint) const
{
u32 num_groups = be_u32(m_slice.offset_pointer((u32)Table12Offsets::NumGroups));
- ASSERT(m_slice.size() >= (u32)Table12Sizes::Header + (u32)Table12Sizes::Record * num_groups);
+ VERIFY(m_slice.size() >= (u32)Table12Sizes::Header + (u32)Table12Sizes::Record * num_groups);
for (u32 offset = 0; offset < num_groups * (u32)Table12Sizes::Record; offset += (u32)Table12Sizes::Record) {
u32 start_codepoint = be_u32(m_slice.offset_pointer((u32)Table12Offsets::Record_StartCode + offset));
if (codepoint < start_codepoint) {