Silence some silly clippy warnings on generated code.

This commit is contained in:
Nathan Vegdahl 2019-08-01 13:43:32 +09:00
parent 0c99ce8227
commit 95e7d6bdea

View File

@ -28,6 +28,8 @@ fn main() {
.unwrap();
f.write_all(format!("\nconst REC709_TABLE_MID_VALUE: f32 = {};", MID_VALUE).as_bytes())
.unwrap();
f.write_all("\n#[allow(clippy::unreadable_literal, clippy::approx_constant)]".as_bytes())
.unwrap();
f.write_all("\npub static REC709_TABLE: &[[(f32, f32, f32); 2]; 64 * 64 * 3] = &[".as_bytes())
.unwrap();
for item in &rec709_table {
@ -48,6 +50,8 @@ fn main() {
.unwrap();
f.write_all(format!("\nconst REC2020_TABLE_MID_VALUE: f32 = {};", MID_VALUE).as_bytes())
.unwrap();
f.write_all("\n#[allow(clippy::unreadable_literal, clippy::approx_constant)]".as_bytes())
.unwrap();
f.write_all("\npub static REC2020_TABLE: &[[(f32, f32, f32); 2]; 64 * 64 * 3] = &[".as_bytes())
.unwrap();
for item in &rec2020_table {
@ -68,6 +72,8 @@ fn main() {
.unwrap();
f.write_all(format!("\nconst ACES_TABLE_MID_VALUE: f32 = {};", MID_VALUE).as_bytes())
.unwrap();
f.write_all("\n#[allow(clippy::unreadable_literal, clippy::approx_constant)]".as_bytes())
.unwrap();
f.write_all("\npub static ACES_TABLE: &[[(f32, f32, f32); 2]; 64 * 64 * 3] = &[".as_bytes())
.unwrap();
for item in &aces_table {