Skip to content

R 4.6 compatibility updates:#211

Merged
giovannic merged 2 commits into
masterfrom
bug/iter
Jun 8, 2026
Merged

R 4.6 compatibility updates:#211
giovannic merged 2 commits into
masterfrom
bug/iter

Conversation

@giovannic

Copy link
Copy Markdown
Member
  • Make IterableBitset iterator compatible with C++20
  • Fix cheeky bug in fast_bernoulli where the probability member is unintentionally shadowed
  • Fix compiler warnings for fast bernoulli and (un)signed size comparisons in bitset api

giovannic added 2 commits June 8, 2026 09:31
 * Make IterableBitset iterator compatible with C++20
 * Fix compiler warnings for fast bernoulli and (un)signed size
   comparisons

@M-Kusumgar M-Kusumgar left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All seems reasonable, nice bug fix as well, I'm a bit unsure about the allocator removal or even why you were allocating in the first place, I think I'm missing some context but otherwise all looks good!

Comment on lines +37 to +41
using value_type = size_t;
using reference = size_t&;
using const_reference = const size_t&;
using difference_type = std::ptrdiff_t;
using size_type = std::size_t;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for my understanding, why were you allocating vs not now?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was written when C++14 was the default and std::allocator members were a thing. In c++17 they were deprecated because they are redundant. And in C++20 they were removed

@giovannic giovannic marked this pull request as ready for review June 8, 2026 09:55
@giovannic giovannic merged commit 50524f2 into master Jun 8, 2026
5 checks passed
@giovannic giovannic deleted the bug/iter branch June 8, 2026 09:55
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.

2 participants