Skip to content

Commit 421f92b

Browse files
committed
make some debug assertions in RangeObjectMap be full assertions
1 parent fa7811b commit 421f92b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/concurrency/range_object_map.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,11 +117,11 @@ impl<T> RangeObjectMap<T> {
117117
self.v.insert(pos, Elem { range, data });
118118
// If we aren't the first element, then our start must be greater than the preivous element's end
119119
if pos > 0 {
120-
debug_assert!(self.v[pos - 1].range.end() <= range.start);
120+
assert!(self.v[pos - 1].range.end() <= range.start);
121121
}
122122
// If we aren't the last element, then our end must be smaller than next element's start
123123
if pos < self.v.len() - 1 {
124-
debug_assert!(range.end() <= self.v[pos + 1].range.start);
124+
assert!(range.end() <= self.v[pos + 1].range.start);
125125
}
126126
}
127127

0 commit comments

Comments
 (0)