Skip to content
This repository was archived by the owner on Sep 20, 2023. It is now read-only.
This repository was archived by the owner on Sep 20, 2023. It is now read-only.

String with Encoding #85

@vincenthz

Description

@vincenthz

Expose a String type with a slightly different name that doesn't assume one specific encoding.

data EString encoding = EString (UArray Word8)

where encoding are specific disjoint types like UTF8 or UTF16.

class Encoding e
   ...
data UTF8
instance Encoding UTF8
data UTF16
instance Encoding UTF16

Operation would look like:

break :: Encoding e => (Char -> Bool) -> EString e -> (EString e, EString e)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions