Open akhilman opened 4 hours ago
I have an error:
error[E0624]: method `iter` is private --> src/main.rs:12:10 | 3 | #[derive(Debug, StructOfArray)] | ------------- private method defined here ... 12 | mega.iter().for_each(|row| { | ^^^^ private method
In this code:
use soa_derive::StructOfArray; #[derive(Debug, StructOfArray)] #[soa_derive(Debug)] struct MegaStruct { foo: usize, bar: usize, } fn main() { let mega = MegaStructVec::default(); mega.iter().for_each(|row| { println!("{:?}", row); }); }
What I am doing wrong?
Ok. Fount a cause. The struct should be public to make iter accessible.
I have an error:
In this code:
What I am doing wrong?