Skip to content

Add fromPtr variant that is NULL-terminated #304

Description

@sjshuck

For my case, I need to copy a region of UTF-16 text from the heap into a Text. It is NULL (U+0000) terminated.

Currently I'm scanning each 16-bit code unit in a loop to detemine the length and then calling Data.Text.Foreign.fromPtr, but I wonder if an easier method can be provided.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions