Skip to content

💥 Adjust bitset API#367

Merged
bdeane-intel merged 1 commit into
intel:mainfrom
elbeno:bitset-empty
May 28, 2026
Merged

💥 Adjust bitset API#367
bdeane-intel merged 1 commit into
intel:mainfrom
elbeno:bitset-empty

Conversation

@elbeno
Copy link
Copy Markdown
Contributor

@elbeno elbeno commented May 28, 2026

Problem:

  • The API of bitset is different enough from the API of std::set that it is difficult to use generically. This prevents tests from using std::set for clarity where the implementation expects a bitset.

Solution:

  • Adjust the API of bitset. In particular:
    • size() becomes dynamic
    • capacity() replaces static size()
    • empty() is synonymous with none()
    • clear() is synonymous with reset()

Problem:
- The API of `bitset` is different enough from the API of `std::set` that it is
  difficult to use generically. This prevents tests from using `std::set` for
  clarity where the implementation expects a `bitset`.

Solution:
- Adjust the API of bitset. In particular:
  - `size()` becomes dynamic
  - `capacity()` replaces static `size()`
  - `empty()` is synonymous with `none()`
  - `clear()` is synonymous with `reset()`
@bdeane-intel bdeane-intel merged commit e5f8651 into intel:main May 28, 2026
27 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants