certain non-decomposable senders caus a compilation error
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 48/100
Research direction
Reproduce the compilation error from the example using beman/execution/execution.hpp and ex::get_completion_signatures. Inspect ex::tag_of_t and the basic_sender detection path to understand why the two-argument non_decomposable_sender is treated as decomposable. Done means the example compiles without removing a constructor parameter, with coverage for this regression.
Written by the indexing model from the issue text.
Description
The following code results in a compilation error:
#include <beman/execution/execution.hpp>
namespace ex = beman::execution;
namespace {
struct non_decomposable_sender {
using sender_concept = ex::sender_t;
template <typename...>
static consteval auto get_completion_signatures() { return test_std::completion_signatures<ex::set_value_t()>(); }
non_decomposable_sender(int, int) {}
};
}
int main() {
(void)ex::get_completion_signatures<non_decomposible_sender, ex::env<>>();
}
Removing one of the int constructor parameters causes the code to compile!
The issue is that sender is used with ex::tag_of_t which tries to guess whether a type is decomposable. If it think it can decompose objects of a type it will extract a tag. However, the above type can't be decomposed.
Currently, I don't know how to properly fix the problem. The tentative plan is to rather detect if a sender is built using basic_sender (probably indirectly by actually detecting a nested type) and only try to decompose such senders.
- Dominant language
- C++
- Stars
- 150
- Forks
- 23
- Avg merge
- 3d 5h
- Merged PRs (30d)
- 9
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from bemanproject/execution
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
bemanproject/execution#247 · 1 comment · 3 reactions ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
bemanproject/execution#246 · 1 comment · 1 reaction ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
bemanproject/execution#245 · 4 comments ·
-
Difficulty 3/5 1-2 days Newbie friendliness 25/100
bemanproject/execution#248 · 1 reaction ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
bemanproject/execution#207 · 7 comments ·
All issues in bemanproject/execution
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
google/libultrahdr#485 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
godotengine/godot#123776 ·
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 60/100
-
good first issue
Difficulty 1/5 Under an hour Newbie friendliness 90/100
-
good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
ros2/common_interfaces#344 ·