Implement free reset on SparseByteSet + parametrize with size.
- Dominant language
- C++
- Stars
- 30.5k
- Forks
- 5.9k
- PR merge metrics
- No merged PRs in 30d
Description
1. [Here](https://github.com/facebook/folly/blob/main/folly/container/SparseByteSet.h) we can make free reset of all data structure with this simple method:
`void reset() { size_ = 0; }`
Why this class insert-only now?
2. Arrays size is defined as internal constexpr variable. We make this class more useful if user can parametrize it with size. We also can deduce needed types for `size_` and arrays from size on compile time.
Contributor guide
Research direction
Read folly/container/SparseByteSet.h first, focusing on the current reset behavior, the internal constexpr array size, size_, and the existing insert-only design. Define what a parameterized size should mean for the class and how the related types derive from it at compile time. Done means the data structure supports free reset and user-selected size without breaking its existing behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100