• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

STEllAR-GROUP / hpx / #633
83%

Build:
DEFAULT BRANCH: master
Ran 14 Dec 2021 12:12PM UTC
Jobs 1
Files 2361
Run time 11min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

14 Dec 2021 09:50AM UTC coverage: 85.888% (+0.3%) from 85.567%
#633

push

msimberg
Merge #5674

5674: Allow using  `any_sender` in global variables r=msimberg a=msimberg

## Proposed Changes

This allows storing `(unique_)any_sender` in global variables (or even function-local statics). The problem is that the destructor of the `any_sender` may hold e.g. hold an `any_operation_state/receiver` from a type-erased predecessor sender. When the global `any_sender` is destroyed it may try to access an empty vtable that was destroyed before the global `any_sender` was destroyed. The failure case in the added test is a segfault. The `empty` method on the (supposed) empty vtable happens to return `false` and the destructor tries to delete the empty vtable even though it was never dynamically allocated.

~This changes the empty vtables to be `inline constexpr` variables.~ This adds a helper base class which accesses the `any_operation_state` and `any_receiver` empty vtables when constructing `(unique_)any_sender`.

Flyby:
- Remove `explicit` from the `(unique_)any_sender` constructors. It's very convenient to be able to simply assign any sender to a `(unique_)any_sender` without spelling out the type.

## Checklist

Not all points below apply to all pull requests.

- [ ] I have added a new feature and have added tests to go along with it.
- [x] I have fixed a bug and have added a regression test.
- [ ] I have added a test using random numbers; I have made sure it uses a seed, and that random numbers generated are valid inputs for the tests.


Co-authored-by: Mikael Simberg <mikael.simberg@iki.fi>

152 of 152 new or added lines in 2 files covered. (100.0%)

164156 of 191127 relevant lines covered (85.89%)

2197457.3 hits per line

Jobs
ID Job ID Ran Files Coverage
1 #633.1 14 Dec 2021 12:12PM UTC 0
85.89
Source Files on build #633
Detailed source file information is not available for this build.
  • Back to Repo
  • bf30eeb1 on github
  • Prev Build on master
  • Next Build on master
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc