Skip to content

Bucket::drop and Bucket::read need to be used with deprecated RawTable::erase_no_drop #364

@JustForFun88

Description

@JustForFun88

I'm trying to document a raw part of the crate and was thinking about the safety concerns of the Bucket<T> methods, but I suddenly realized that the two public methods, Bucket::drop and Bucket::read, potentially lead to double-drop in RawTable, since they cannot be used without RawTable::erase_no_drop but this method has been deprecated since version "0.8.1".

So we need to come up with something:

  • make Bucket::drop and Bucket::read deprecated too;
  • make RawTable::erase_no_drop not a deprecated method;
  • separately document these potential double-drop for Bucket::drop and Bucket::read methods? But it is not clear how to document this for Bucket::drop, the Bucket::read method can at least be used in conjunction with core::mem::forget.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions