-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
I managed to shoot myself in the foot by reading back an array that was set via setListCountAndRef by extracting the Ptr near the end of the lifetime of a struct, followed by reading the array with peekArray. Because the array lifetime is coupled to the struct lifetime, this caused the array to be overwritten sometimes before peekArray was finished.
While that's entirely my fault, it would be nice to have more field accessor functions. I already have some in Program.Foreign: withUnsafeField, getListCountAndRef. (Besides, the function withArrayLen from this module should probably be in Graphics.Vulkan.Marshal). Not making a pull request because I don't know where to put them, and I guess they can be done without IO somehow.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels