[OTLayout] Remove operator() from ClassDef
This commit is contained in:
parent
b67881b171
commit
2dc1141d7d
|
@ -754,8 +754,6 @@ struct ClassDefFormat2
|
|||
|
||||
struct ClassDef
|
||||
{
|
||||
inline unsigned int operator () (hb_codepoint_t glyph_id) const { return get_class (glyph_id); }
|
||||
|
||||
inline unsigned int get_class (hb_codepoint_t glyph_id) const
|
||||
{
|
||||
switch (u.format) {
|
||||
|
|
|
@ -736,8 +736,8 @@ struct PairPosFormat2
|
|||
unsigned int len2 = valueFormat2.get_len ();
|
||||
unsigned int record_len = len1 + len2;
|
||||
|
||||
unsigned int klass1 = (this+classDef1) (c->buffer->cur().codepoint);
|
||||
unsigned int klass2 = (this+classDef2) (c->buffer->info[skippy_iter.idx].codepoint);
|
||||
unsigned int klass1 = (this+classDef1).get_class (c->buffer->cur().codepoint);
|
||||
unsigned int klass2 = (this+classDef2).get_class (c->buffer->info[skippy_iter.idx].codepoint);
|
||||
if (unlikely (klass1 >= class1Count || klass2 >= class2Count)) return TRACE_RETURN (false);
|
||||
|
||||
const Value *v = &values[record_len * (klass1 * class2Count + klass2)];
|
||||
|
|
|
@ -1192,7 +1192,7 @@ struct ContextFormat2
|
|||
TRACE_WOULD_APPLY (this);
|
||||
|
||||
const ClassDef &class_def = this+classDef;
|
||||
unsigned int index = class_def (c->glyphs[0]);
|
||||
unsigned int index = class_def.get_class (c->glyphs[0]);
|
||||
const RuleSet &rule_set = this+ruleSet[index];
|
||||
struct ContextApplyLookupContext lookup_context = {
|
||||
{match_class},
|
||||
|
@ -1213,7 +1213,7 @@ struct ContextFormat2
|
|||
if (likely (index == NOT_COVERED)) return TRACE_RETURN (false);
|
||||
|
||||
const ClassDef &class_def = this+classDef;
|
||||
index = class_def (c->buffer->cur().codepoint);
|
||||
index = class_def.get_class (c->buffer->cur().codepoint);
|
||||
const RuleSet &rule_set = this+ruleSet[index];
|
||||
struct ContextApplyLookupContext lookup_context = {
|
||||
{match_class},
|
||||
|
@ -1752,7 +1752,7 @@ struct ChainContextFormat2
|
|||
|
||||
const ClassDef &input_class_def = this+inputClassDef;
|
||||
|
||||
unsigned int index = input_class_def (c->glyphs[0]);
|
||||
unsigned int index = input_class_def.get_class (c->glyphs[0]);
|
||||
const ChainRuleSet &rule_set = this+ruleSet[index];
|
||||
struct ChainContextApplyLookupContext lookup_context = {
|
||||
{match_class},
|
||||
|
@ -1776,7 +1776,7 @@ struct ChainContextFormat2
|
|||
const ClassDef &input_class_def = this+inputClassDef;
|
||||
const ClassDef &lookahead_class_def = this+lookaheadClassDef;
|
||||
|
||||
index = input_class_def (c->buffer->cur().codepoint);
|
||||
index = input_class_def.get_class (c->buffer->cur().codepoint);
|
||||
const ChainRuleSet &rule_set = this+ruleSet[index];
|
||||
struct ChainContextApplyLookupContext lookup_context = {
|
||||
{match_class},
|
||||
|
|
Loading…
Reference in New Issue