Get actual size beforehand #264
Unanswered
NefixEstrada
asked this question in
Q&A
Replies: 1 comment 1 reply
-
binrw does not currently calculate the size of a struct at compile time. You could annotate it yourself with e.g. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello!
Is it possible to know the size that will have a struct beforehand?
So, having,
Is it possible to know that the size that the struct will have will be
4
at comptime?Could also be added as
#[brw(calc(SOMETHING))]
for another struct? Or the struct itself?Thank you!
Beta Was this translation helpful? Give feedback.
All reactions