Skip to content

Commit

Permalink
HACK: Scheduler Workaround
Browse files Browse the repository at this point in the history
  • Loading branch information
skoppe committed Aug 10, 2024
1 parent 481a25f commit f997829
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion examples/iouring/source/app.d
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import concurrency.socket;
import concurrency.io;
import concurrency.operations.whenall;

void main()
void main() @safe
{
auto fd = listen("127.0.0.1", 0);
auto io = IOUringContext.construct(256);
Expand Down
3 changes: 2 additions & 1 deletion source/concurrency/operations/whenall.d
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,8 @@ import std.meta : allSatisfy, ApplyRight;

struct WhenAllSender(Senders...)
if ((Senders.length > 1
&& allSatisfy!(ApplyRight!(models, isSender), Senders))
//&& allSatisfy!(ApplyRight!(models, isSender), Senders)
)
|| (models!(ArrayElement!(Senders[0]), isSender))) {
alias Result = WhenAllResult!(Senders);
static if (hasMember!(Result, "values"))
Expand Down
4 changes: 2 additions & 2 deletions source/concurrency/operations/withscheduler.d
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ private struct WithSchedulerReceiver(Receiver, Value, Scheduler) {
mixin ForwardExtensionPoints!receiver;
}

struct WithSchedulerSender(Sender, Scheduler) if (models!(Sender, isSender)) {
static assert(models!(typeof(this), isSender));
struct WithSchedulerSender(Sender, Scheduler) { //if (models!(Sender, isSender)) {
//static assert(models!(typeof(this), isSender));
alias Value = Sender.Value;
Sender sender;
Scheduler scheduler;
Expand Down

0 comments on commit f997829

Please sign in to comment.