[subset] Always output Lookup's even if they are empty.

The rest of layout subsetting depends on lookup indices being consistent with those computed during planning. So if an empty lookup is discarded during the subset phase it will invalidate all subsequent lookup indices. Generally we shouldn't end up with an empty lookup as we pre-prune them during the planning phase, but it can happen in rare cases such as when a subtable is considered degenerate (eg. #3853)
This commit is contained in:
Garret Rieger 2022-10-21 22:33:17 +00:00 committed by Behdad Esfahbod
parent 3377ddf69e
commit 70e2de2bd4
1 changed files with 2 additions and 2 deletions

View File

@ -1388,7 +1388,7 @@ struct Lookup
outMarkFilteringSet = markFilteringSet;
}
return_trace (out->subTable.len);
return true;
}
template <typename TSubTable>
@ -2948,7 +2948,7 @@ struct ConditionSet
// all conditions met
if (num_kept_cond == 0) return DROP_COND_WITH_VAR;
//check if condition_set is unique with variations
if (c->conditionset_map->has (p))
//duplicate found, drop the entire record