Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restructure modules #18

Open
andrewthad opened this issue Apr 4, 2020 · 0 comments
Open

Restructure modules #18

andrewthad opened this issue Apr 4, 2020 · 0 comments

Comments

@andrewthad
Copy link
Member

Currently, bytebuild just dumps all kinds of encodings into a single module. By contrast, bytesmith breaks things up a little better:

Data.Bytes.Parser
    Data.Bytes.Parser.Ascii
    Data.Bytes.Parser.BigEndian
    Data.Bytes.Parser.Latin
    Data.Bytes.Parser.LittleEndian
    Data.Bytes.Parser.Unsafe
    Data.Bytes.Parser.Utf8

This nicest thing about this is that big-endian and little-endian encodings are almost never used together. There's less opportunity to make a mistake using the library when the combinators you don't want to use aren't in scope. It also helps avoid goofy suffixed names.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant