Skip to content

Commit ab3aaf8

Browse files
authored
Revert "[match-backtrack] Fix syllable-setting logic (#290)" (#291)
This reverts commit c5b6cb0. Revert, like HB, while we figure out what's the safe way forward: harfbuzz/harfbuzz#5620 harfbuzz/harfbuzz#5618
1 parent c5b6cb0 commit ab3aaf8

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

src/hb/ot_layout_gsubgpos.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ pub fn match_backtrack(
153153
match_start: &mut usize,
154154
) -> bool {
155155
let mut iter = skipping_iterator_t::with_match_fn(ctx, true, Some(match_func));
156-
iter.reset_back(iter.buffer.backtrack_len());
156+
iter.reset(iter.buffer.backtrack_len());
157157
iter.set_glyph_data(0);
158158

159159
for _ in 0..backtrack_len {
@@ -436,7 +436,6 @@ where
436436
}
437437

438438
pub fn reset(&mut self, start_index: usize) {
439-
// For GSUB forward iterator
440439
self.buf_idx = start_index;
441440
self.buf_len = self.buffer.len;
442441
self.syllable = if self.buf_idx == self.buffer.idx {
@@ -446,12 +445,6 @@ where
446445
};
447446
}
448447

449-
pub fn reset_back(&mut self, start_index: usize) {
450-
// For GSUB backward iterator
451-
self.buf_idx = start_index;
452-
self.syllable = 0;
453-
}
454-
455448
pub fn reset_fast(&mut self, start_index: usize) {
456449
// Doesn't set end or syllable. Used by GPOS which doesn't care / change.
457450
self.buf_idx = start_index;

0 commit comments

Comments
 (0)