Skip to content

Implement bytemuck traits where appropriate #286

Description

@eira-fransham

A nice optimisation provided by bytemuck is the ability to do zeroed heap allocations using calloc safely. Since the default parking_lot Mutex and RwLock have an all-zeroes default state, then this means for any safely zeroable type T, RwLock<T> and Mutex<T> are also safely zeroable - and, by extension, FairMutex too. ReentrantMutex is not, however. Implementing these traits - even if behind a feature gate - would make some use-cases using collections of mutexes faster.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions