Skip to content

Roadmap #48

Open
Open
@TimDiekmann

Description

@TimDiekmann
Member

I would like to come to the listed issues in the more or less indicated order. Linked issues are not necessarily confirmed, please consult the issues for more details.

AllocRef:

Allocator aware types:

GlobalAlloc:

  • Coherent design of GlobalAlloc and Alloc #21: Coherent design of GlobalAlloc and Alloc
    Implement AllocRef on System without GlobalAlloc #43: Implement AllocRef on System without GlobalAlloc
    soft-deprecate GlobalAlloc when stabilizing AllocRef
    deprecate GlobalAlloc when AllocRef is stabilized at least three months (two versions)

Documentation:

Other:

  • Rename AllocErr to AllocError #57: Rename AllocErr to AllocError

Activity

self-assigned this
on Mar 12, 2020
pinned this issue on Mar 12, 2020
TimDiekmann

TimDiekmann commented on Mar 28, 2020

@TimDiekmann
MemberAuthor

Updated OP.

Wodann

Wodann commented on Apr 25, 2020

@Wodann

@TimDiekmann what are next steps? Are we waiting for potential feedback from users on our changes to the API before we proceed?

TimDiekmann

TimDiekmann commented on Apr 25, 2020

@TimDiekmann
MemberAuthor

I'm currently testing the API with alloc-compose. I also testing out, on how well taking &self is working. While most allocators could use &self instead of &mut self this has a major downside: Cell is !Sync, so using internal mutability for Sync allocators have to use atomics or other structs, which introduce more overhead. For the same reason, Bump from bumpalo is also !Sync.

Amanieu

Amanieu commented on Apr 25, 2020

@Amanieu
Member

I think those downside of &self are actually advantages, see #55.

SimonSapin

SimonSapin commented on Apr 26, 2020

@SimonSapin
Contributor
  • deprecate GlobalAlloc

Actively emitting deprecation warnings causes churn. What benefit does this bring in exchange?

  • add #[doc(hidden)] to GlobalAlloc

GlobalAlloc is stable, so there will always be legacy code that uses it (even if with deprecating warnings). Hiding its docs would be confusing to future readers of such code, for what benefit? Compared to documenting that using AllocRef instead is preferred.

TimDiekmann

TimDiekmann commented on Apr 26, 2020

@TimDiekmann
MemberAuthor

Isn't that the point of deprecation warnings? Error::source was introduced in 1.30, Error::cause was deprecated in 1.33. I expect many more people to use the Error trait than the GlobalAlloc trait. Sure, we could also just leave GlobalAlloc alone 🙂

Hiding its docs would be confusing to future readers of such code

Fair point.

Wodann

Wodann commented on Aug 5, 2020

@Wodann

@TimDiekmann Could you update the roadmap with recent changes and what's left for us to do?

Also, can we proceed with #7 now that unstable generic trait instantiations are supported?

changed the title [-]Roadmap for `AllocRef`[/-] [+]Roadmap[/+] on Aug 5, 2020
TimDiekmann

TimDiekmann commented on Aug 5, 2020

@TimDiekmann
MemberAuthor

Updated the roadmap.

Also, can we proceed with #7 now that unstable generic trait instantiations are supported?

rust-lang/rust#72314 is not merged yet as @varkor asked for a few more tests. I will open a new issue for each collection when it's merged.

Wodann

Wodann commented on Aug 5, 2020

@Wodann

Thanks for cleaning up the roadmap and outstanding issues 👍

11 remaining items

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

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Development

    No branches or pull requests

      Participants

      @berkus@Amanieu@SimonSapin@jmillikin@yanchith

      Issue actions

        Roadmap · Issue #48 · rust-lang/wg-allocators