Open KislyjKisel opened 5 months ago
A million years later, but is this still an issue? Did you check the c2ffi output, or try with a newer clang? I don't think autowrap/sffi itself does any computation for field offsets (outside of array indexing).
c2ffi outputs fields with offsets relative to the nearest parent record. autowrap seems to account for this with pre-offset
parameter. Here, if I understand correctly, nested records are parsed, but their pre-offset
is set to the field's bit-offset
. If the field's bit-offset
isn't absolute there, than it should be (+ pre-offset (or bit-offset 0))
instead.
C definition: https://github.com/blend2d/blend2d/blob/597ea5d5c35c6d3dfdc2329316f1d8ba25929404/src/blend2d/format.h#L118-L141
r-size
andsizes
are expected to have the same address aspalette
because they are in the same union, but instead have the address of the parent struct, same asdepth
.Platform: Linux x86-64, SBCL.