-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Closed
Description
Usually when reading data from network or from binary file there is no guarantee that data will be placed in memory with respect to alignment. So, trying to use such memory buffers as is will lead to precondition.
In swift 5.7 there is a new loadUnaligned function is available, so plain data types can be accessed without respect to alignment. So, seems that means by using loadUnaligned
we can create flatbuffer from any buffer and it will work normally.
So, I suggest to start using loadUnaligned
instead of load
. storeBytes
works without changing function signature. Do i miss anything?
Metadata
Metadata
Assignees
Labels
No labels