Rename VAR to HB_VAR_ARRAY

This commit is contained in:
Behdad Esfahbod 2019-09-06 16:54:27 -04:00
parent c379faed2b
commit 0e294c455e
8 changed files with 14 additions and 14 deletions

View File

@ -135,7 +135,7 @@ static inline Type& StructAfter(TObject &X)
#define DEFINE_SIZE_ARRAY(size, array) \
DEFINE_COMPILES_ASSERTION ((void) (array)[0].static_size) \
DEFINE_INSTANCE_ASSERTION (sizeof (*this) == (size) + VAR * sizeof ((array)[0])) \
DEFINE_INSTANCE_ASSERTION (sizeof (*this) == (size) + HB_VAR_ARRAY * sizeof ((array)[0])) \
static constexpr unsigned null_size = (size); \
static constexpr unsigned min_size = (size)

View File

@ -483,7 +483,7 @@ struct UnsizedArrayOf
}
public:
Type arrayZ[VAR];
Type arrayZ[HB_VAR_ARRAY];
public:
DEFINE_SIZE_UNBOUNDED (0);
};
@ -669,7 +669,7 @@ struct ArrayOf
public:
LenType len;
Type arrayZ[VAR];
Type arrayZ[HB_VAR_ARRAY];
public:
DEFINE_SIZE_ARRAY (sizeof (LenType), arrayZ);
};
@ -802,7 +802,7 @@ struct HeadlessArrayOf
public:
LenType lenP1;
Type arrayZ[VAR];
Type arrayZ[HB_VAR_ARRAY];
public:
DEFINE_SIZE_ARRAY (sizeof (LenType), arrayZ);
};
@ -850,7 +850,7 @@ struct ArrayOfM1
public:
LenType lenM1;
Type arrayZ[VAR];
Type arrayZ[HB_VAR_ARRAY];
public:
DEFINE_SIZE_ARRAY (sizeof (LenType), arrayZ);
};

View File

@ -237,8 +237,8 @@ struct CFFIndex
public:
COUNT count; /* Number of object data. Note there are (count+1) offsets */
HBUINT8 offSize; /* The byte size of each offset in the offsets array. */
HBUINT8 offsets[VAR]; /* The array of (count + 1) offsets into objects array (1-base). */
/* HBUINT8 data[VAR]; Object data */
HBUINT8 offsets[HB_VAR_ARRAY]; /* The array of (count + 1) offsets into objects array (1-base). */
/* HBUINT8 data[HB_VAR_ARRAY]; Object data */
public:
DEFINE_SIZE_ARRAY (COUNT::static_size + HBUINT8::static_size, offsets);
};
@ -514,7 +514,7 @@ struct FDSelect0 {
unsigned int get_size (unsigned int num_glyphs) const
{ return HBUINT8::static_size * num_glyphs; }
HBUINT8 fds[VAR];
HBUINT8 fds[HB_VAR_ARRAY];
DEFINE_SIZE_MIN (0);
};

View File

@ -357,7 +357,7 @@ struct Charset0 {
return HBUINT16::static_size * (num_glyphs - 1);
}
HBUINT16 sids[VAR];
HBUINT16 sids[HB_VAR_ARRAY];
DEFINE_SIZE_ARRAY(0, sids);
};
@ -439,7 +439,7 @@ struct Charset1_2 {
return size;
}
Charset_Range<TYPE> ranges[VAR];
Charset_Range<TYPE> ranges[HB_VAR_ARRAY];
DEFINE_SIZE_ARRAY (0, ranges);
};

View File

@ -780,7 +780,7 @@ struct Lookup
HBUINT16 lookupFlag; /* Lookup qualifiers */
ArrayOf<Offset16>
subTable; /* Array of SubTables */
/*HBUINT16 markFilteringSetX[VAR];*//* Index (base 0) into GDEF mark glyph sets
/*HBUINT16 markFilteringSetX[HB_VAR_ARRAY];*//* Index (base 0) into GDEF mark glyph sets
* structure. This field is only present if bit
* UseMarkFilteringSet of lookup flags is set. */
public:

View File

@ -129,7 +129,7 @@ struct maxp
FixedVersion<>version; /* Version of the maxp table (0.5 or 1.0),
* 0x00005000u or 0x00010000u. */
HBUINT16 numGlyphs; /* The number of glyphs in the font. */
/*maxpV1Tail v1Tail[VAR]; */
/*maxpV1Tail v1Tail[HB_VAR_ARRAY]; */
public:
DEFINE_SIZE_STATIC (6);
};

View File

@ -48,7 +48,7 @@ static const union HB_STRING_ARRAY_TYPE_NAME {
#include HB_STRING_ARRAY_LIST
#undef _S
} st;
char str[VAR];
char str[HB_VAR_ARRAY];
}
HB_STRING_ARRAY_POOL_NAME =
{

View File

@ -475,7 +475,7 @@ static_assert ((sizeof (hb_var_int_t) == 4), "");
/* Size signifying variable-sized array */
#define VAR 1
#define HB_VAR_ARRAY 1
static inline double
_hb_roundf (float x)