1
0
Fork 0
mirror of https://github.com/alacritty/alacritty.git synced 2024-11-18 13:55:23 -05:00

Fix failing test with bench feature

Using the `bench` feature, `cargo test` was failing since one of the
benchmarks was running into a debug assertion for attempting to access a
line with an index beyond the grid length.

Since this issue was caused by the `len` property not being serialized
and deserialized, the `#[serde(skip)]` attribute has been changed to
`#[serde(default)]`. The ref-test has been edited to include the correct
grid length for proper deserialization.

This fixes #1604.
This commit is contained in:
Christian Duerr 2018-09-29 20:48:24 +00:00 committed by GitHub
parent 1887722ef5
commit e01317d885
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -32,7 +32,7 @@ pub struct Storage<T> {
/// having to truncate the raw `inner` buffer. /// having to truncate the raw `inner` buffer.
/// As long as `len` is bigger than `inner`, it is also possible to grow the scrollback buffer /// As long as `len` is bigger than `inner`, it is also possible to grow the scrollback buffer
/// without any additional insertions. /// without any additional insertions.
#[serde(skip)] #[serde(default)]
len: usize, len: usize,
} }

File diff suppressed because one or more lines are too long