mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
Make set_char_is_space mutate self in place
This commit is contained in:
parent
e663005ce2
commit
4174c918ad
1 changed files with 3 additions and 3 deletions
|
@ -129,8 +129,8 @@ impl GlyphEntry {
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline(always)]
|
#[inline(always)]
|
||||||
fn set_char_is_space(&self) -> GlyphEntry {
|
fn set_char_is_space(&mut self) {
|
||||||
GlyphEntry::new(self.value | FLAG_CHAR_IS_SPACE)
|
self.value |= FLAG_CHAR_IS_SPACE;
|
||||||
}
|
}
|
||||||
|
|
||||||
fn glyph_count(&self) -> u16 {
|
fn glyph_count(&self) -> u16 {
|
||||||
|
@ -487,7 +487,7 @@ impl<'a> GlyphStore {
|
||||||
};
|
};
|
||||||
|
|
||||||
if character == ' ' {
|
if character == ' ' {
|
||||||
entry = entry.set_char_is_space()
|
entry.set_char_is_space()
|
||||||
}
|
}
|
||||||
|
|
||||||
self.entry_buffer[i.to_usize()] = entry;
|
self.entry_buffer[i.to_usize()] = entry;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue