Skip to content

Use well-typed errors #13

Open
@JarvisCraft

Description

@JarvisCraft

Problem

Currently, enum Error is just a bunch of typed Strings which has the cons of:

  • Being hard to use it in granular manner;
  • Requiring allocations per each string which may never be used.

There also is a problem of not using the std::error::Error::source() infra.

Solution

Replace this with a well-typed error using thiserror for declarative definition.


PS: self-assigning the issue as I am already working on it.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions