[aat] Reduce unsafe_to_concat calls

This commit is contained in:
Behdad Esfahbod 2023-01-10 13:23:19 -07:00
parent 8b17c6ca30
commit dd42939e31
3 changed files with 5 additions and 2 deletions

View File

@ -783,8 +783,6 @@ struct StateTableDriver
if (!c->in_place)
buffer->clear_output ();
buffer->unsafe_to_concat ();
int state = StateTableT::STATE_START_OF_TEXT;
// If there's only one range, we already checked the flag.
auto *last_range = ac->range_flags && (ac->range_flags->length > 1) ? &(*ac->range_flags)[0] : nullptr;

View File

@ -869,6 +869,8 @@ struct KerxTable
bool apply (AAT::hb_aat_apply_context_t *c) const
{
c->buffer->unsafe_to_concat ();
typedef typename T::SubTable SubTable;
bool ret = false;

View File

@ -1154,6 +1154,9 @@ struct mortmorx
const hb_aat_map_t &map) const
{
if (unlikely (!c->buffer->successful)) return;
c->buffer->unsafe_to_concat ();
c->set_lookup_index (0);
const Chain<Types> *chain = &firstChain;
unsigned int count = chainCount;