Skip to content

Need simpler way to get a PrimBytes field from a Ptr #21

@Rotaerk

Description

@Rotaerk

If I have a Ptr Foo, where Foo has a bar :: Word32 field, I can get that field's value like:

bPeekByteOff @Word32 fooPtr $ bFieldOffsetOf @"bar" (undefined :: Foo)

It would be nice to not have to explicitly specify the type of the field when getting it, as that should be determinable by the field name. It would also be nice to have a single function that covers this, like readField from Graphics.Vulkan.Marshal.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions