No need to put static

This commit is contained in:
Gwilym Kuiper 2021-04-20 23:04:32 +01:00
parent ba2813f927
commit 8575f7d3d6

View file

@ -13,7 +13,7 @@ pub(crate) fn generate_code(
) -> io::Result<()> { ) -> io::Result<()> {
writeln!( writeln!(
output, output,
"pub const PALETTE_DATA: &'static [crate::display::palette16::Palette16] = &[", "pub const PALETTE_DATA: &[crate::display::palette16::Palette16] = &[",
)?; )?;
for palette in &results.optimised_palettes { for palette in &results.optimised_palettes {
@ -33,7 +33,7 @@ pub(crate) fn generate_code(
writeln!(output, "];")?; writeln!(output, "];")?;
writeln!(output)?; writeln!(output)?;
writeln!(output, "pub const TILE_DATA: &'static [u32] = &[",)?; writeln!(output, "pub const TILE_DATA: &[u32] = &[",)?;
let tile_size = tile_size.to_size(); let tile_size = tile_size.to_size();
@ -76,7 +76,7 @@ pub(crate) fn generate_code(
writeln!(output, "];")?; writeln!(output, "];")?;
writeln!(output)?; writeln!(output)?;
write!(output, "pub const PALETTE_ASSIGNMENT: &'static [u8] = &[")?; write!(output, "pub const PALETTE_ASSIGNMENT: &[u8] = &[")?;
for (i, assignment) in results.assignments.iter().enumerate() { for (i, assignment) in results.assignments.iter().enumerate() {
if i % 16 == 0 { if i % 16 == 0 {