Skip to content

newtype instead of bare string in MimeUnrender / ResultStream?Β #999

Open
@phadej

Description

@phadej

Currently we have

mimeUnrender :: Proxy ctype -> ByteString -> Either String a

I think that we should have a wrapper over that String. The same error is also in ResultStream definition:

newtype ResultStream a = ResultStream (forall b. (IO (Maybe (Either String a)) -> IO b) -> IO b)

If newrype is too much at once, I'll be already happy with a type alias. I have no good candidate for the name though.

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