aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTh3Fanbus <Th3Fanbus@users.noreply.github.com>2018-07-26 17:47:14 +0200
committerChristian Duerr <chrisduerr@users.noreply.github.com>2018-07-26 15:47:14 +0000
commitb59fd21cac5f84c02e2df161bad708e440834320 (patch)
tree32d746de65818fcb1b5cfc40294bea8eec53154e
parentf50ca1a54c94fe324d22d985c1acae1ff7c16a80 (diff)
downloadalacritty-b59fd21cac5f84c02e2df161bad708e440834320.tar.gz
alacritty-b59fd21cac5f84c02e2df161bad708e440834320.zip
Replace runtime debug assertions with static asserts on scrollback
-rw-r--r--src/grid/storage.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/grid/storage.rs b/src/grid/storage.rs
index 6a453da6..ad94cf2b 100644
--- a/src/grid/storage.rs
+++ b/src/grid/storage.rs
@@ -223,7 +223,7 @@ impl<T> Storage<T> {
/// instructions. This implementation achieves the swap in only 8 movups
/// instructions.
pub fn swap(&mut self, a: usize, b: usize) {
- debug_assert!(::std::mem::size_of::<Row<T>>() == 32);
+ assert_eq_size!(Row<T>, [u32; 8]);
let a = self.compute_index(a);
let b = self.compute_index(b);