Skip to content

proposal: container/list: Add PopFront() and PopBack() methods #63645

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
allocgator opened this issue Oct 20, 2023 · 4 comments
Closed

proposal: container/list: Add PopFront() and PopBack() methods #63645

allocgator opened this issue Oct 20, 2023 · 4 comments

Comments

@allocgator
Copy link

The container/list package has PushFront and PushBack methods. There could be PopFront and PopBack methods which return the value from the front and back of a list (respectively), and remove it.

Initial proposal

@gopherbot gopherbot added this to the Proposal milestone Oct 20, 2023
@ianlancetaylor ianlancetaylor moved this to Incoming in Proposals Oct 20, 2023
@ianlancetaylor
Copy link
Member

Thanks, but I doubt we are going to touch container/list right now. More interesting would be a version that uses generics to be type-safe and more efficient.

@seankhliao
Copy link
Member

Duplicate of #817

@seankhliao seankhliao marked this as a duplicate of #817 Oct 21, 2023
@seankhliao seankhliao closed this as not planned Won't fix, can't repro, duplicate, stale Oct 21, 2023
@allocgator
Copy link
Author

Is container/list used to emulate a doubly linked list?

@rsc
Copy link
Contributor

rsc commented Dec 4, 2023

This proposal is a duplicate of a previously discussed proposal, as noted above,
and there is no significant new information to justify reopening the discussion.
The issue has therefore been declined as a duplicate.
— rsc for the proposal review group

@rsc rsc moved this from Incoming to Declined in Proposals Dec 4, 2023
@aclements aclements removed this from Proposals Oct 23, 2024
@golang golang locked and limited conversation to collaborators Dec 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants