pub(crate) struct CachedSubtable<'a> {
kind: CachedSubtableKind<'a>,
digest: SetDigest,
coverage: Coverage<'a>,
coverage_cache: Option<Box<CacheCore<KEY_BITS, VALUE_BITS, CACHE_SIZE, <() as SelectAtomic<STORAGE_BITS>>::Type>>>,
fns: &'static KindFns,
apply_sharing: fn(&CachedSubtable<'_>, &mut ApplyContext<'_, '_, '_>, u32, &mut SecondGlyph) -> Option<()>,
}Expand description
A parsed subtable and the functions that apply it.
Fields§
§kind: CachedSubtableKind<'a>§digest: SetDigestThe glyphs the subtable may apply to.
coverage: Coverage<'a>The coverage of the glyph that a match starts at.
coverage_cache: Option<Box<CacheCore<KEY_BITS, VALUE_BITS, CACHE_SIZE, <() as SelectAtomic<STORAGE_BITS>>::Type>>>§fns: &'static KindFnsHow kind applies.
apply_sharing: fn(&CachedSubtable<'_>, &mut ApplyContext<'_, '_, '_>, u32, &mut SecondGlyph) -> Option<()>fns.apply_sharing, kept here for the pair walk.
Implementations§
Source§impl CachedSubtable<'_>
impl CachedSubtable<'_>
Sourcefn coverage_index(&self, glyph: u32) -> Option<u32>
fn coverage_index(&self, glyph: u32) -> Option<u32>
The coverage index of the glyph a match would start at.
Sourcefn coverage_index_uncached(
&self,
glyph: u32,
cache: &CacheCore<KEY_BITS, VALUE_BITS, CACHE_SIZE, <() as SelectAtomic<STORAGE_BITS>>::Type>,
) -> Option<u32>
fn coverage_index_uncached( &self, glyph: u32, cache: &CacheCore<KEY_BITS, VALUE_BITS, CACHE_SIZE, <() as SelectAtomic<STORAGE_BITS>>::Type>, ) -> Option<u32>
Looks up a glyph the cache doesn’t hold, and remembers it. Kept out of line so the walks inline only the cache hit.
Auto Trait Implementations§
impl<'a> Freeze for CachedSubtable<'a>
impl<'a> RefUnwindSafe for CachedSubtable<'a>
impl<'a> Send for CachedSubtable<'a>
impl<'a> Sync for CachedSubtable<'a>
impl<'a> Unpin for CachedSubtable<'a>
impl<'a> UnsafeUnpin for CachedSubtable<'a>
impl<'a> UnwindSafe for CachedSubtable<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more