[morx] Add an unlikely

This commit is contained in:
Behdad Esfahbod committed 2025-11-20 19:16:51 -07:00
1 parent 3aa1868b23
commit 8dcd621739
1 file changed
+1 -1
+1 -1
View File
@@ -487,7 +487,7 @@ struct LigatureSubtable
if (entry.flags & LigatureEntryT::SetComponent)
{
/* Never mark same index twice, in case DontAdvance was used... */
if (match_length && match_positions[(match_length - 1u) % ARRAY_LENGTH (match_positions)] == buffer->out_len)
if (unlikely (match_length && match_positions[(match_length - 1u) % ARRAY_LENGTH (match_positions)] == buffer->out_len))
match_length--;
match_positions[match_length++ % ARRAY_LENGTH (match_positions)] = buffer->out_len;