Skip to content

Commit

Permalink
Enable old glyph assertion
Browse files Browse the repository at this point in the history
The assertion had a note that it should be enabled
when something like debug_assert is available.
  • Loading branch information
pyfisch committed Nov 10, 2018
1 parent b60006a commit a093702
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions components/gfx/text/glyph.rs
Expand Up @@ -223,16 +223,7 @@ impl<'a> DetailedGlyphStore {
entry_offset, glyphs
);

// TODO: don't actually assert this until asserts are compiled
// in/out based on severity, debug/release, etc. This assertion
// would wreck the complexity of the lookup.
//
// See Rust Issue #3647, #2228, #3627 for related information.
//
// do self.detail_lookup.borrow |arr| {
// assert !arr.contains(entry)
// }

debug_assert!(!self.detail_lookup.contains(&entry));
self.detail_lookup.push(entry);
self.detail_buffer.extend_from_slice(glyphs);
self.lookup_is_sorted = false;
Expand Down

0 comments on commit a093702

Please sign in to comment.