Special case the first element in references

This commit is contained in:
Gwilym Kuiper 2022-01-23 19:21:42 +00:00
parent bdeaf346cd
commit 8fcb9e607d

View file

@ -1,3 +1,4 @@
use alloc::vec;
use alloc::vec::Vec; use alloc::vec::Vec;
use hashbrown::HashMap; use hashbrown::HashMap;
@ -77,7 +78,7 @@ impl<'a> VRamManager<'a> {
free_pointer: None, free_pointer: None,
tile_set_to_vram: HashMap::new(), tile_set_to_vram: HashMap::new(),
references: Vec::new(), references: vec![1],
vram_free_pointer: None, vram_free_pointer: None,
} }
} }