packed_struct.rs
packed_struct.rs copied to clipboard
Can we use loops in generated code for arrays?
If someone use something like
#[derive(PackedStruct)]
#[packed_struct(endian = "lsb")]
pub struct Record {
data: [u8; 5000],
csum: u16,
}
Macro will explode with code for data_0, data_1..... data_5000. Compile times become inadequately big, and lsp will hang. Can we mitigate this somehow?