Skip to content

Custom allocator support #34

Open
Open

Description

@thomcc

We could define a custom trait (see how hashbrown does this) to support it prior to the unstable trait landing. This would (at the very least) allow testing allocation fallibility1, if nothing else.

That said, this is a non-trivial amount of work that seems a bit pointless at the moment.

Footnotes

  1. Admittedly, the amount of code that it would allow testing is very small, and the code in question is very straightforward — just a few lines which do nothing but return errors to their caller. ↩

Activity

  1. thomcc commented on May 7, 2024

    @thomcc
    OwnerAuthor

    I think it is not worth it to define a custom trait, but there's no reason we couldn't support core::alloc::Allocator once it is stable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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