Auto merge of #22165 - pyfisch:assert-glyph, r=jdm

Enable old glyph assertion

The assertion had a note that it should be enabled
when something like debug_assert is available.

This must have been disabled since before Rust 1.0 as it uses invalid syntax.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/22165)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-11-16 08:22:43 -05:00 committed by GitHub
commit 050b2bca70
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -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;