Skip to content

[V4] Restore (optional) task context#78

Merged
ConorWilliams merged 9 commits intomodulesfrom
v4-restore-task-context
Apr 1, 2026
Merged

[V4] Restore (optional) task context#78
ConorWilliams merged 9 commits intomodulesfrom
v4-restore-task-context

Conversation

@ConorWilliams
Copy link
Copy Markdown
Owner

@ConorWilliams ConorWilliams commented Apr 1, 2026

Summary by CodeRabbit

  • Refactor
    • Enhanced internal task scheduling and worker context handling for improved type safety and flexibility in asynchronous operations.
    • Refactored invocability model to better support conditional invocation patterns in the task framework.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 1, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 6170b66d-0e12-4c6c-ac0e-2fe01731315f

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • ✅ Review completed - (🔄 Check again to review again)
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch v4-restore-task-context

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@ConorWilliams ConorWilliams changed the base branch from main to modules April 1, 2026 20:37
@ConorWilliams ConorWilliams force-pushed the v4-restore-task-context branch from 60dabfa to 6b09eb6 Compare April 1, 2026 20:38
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
src/core/concepts.cxx (1)

188-191: Consider value category coverage for noexcept detection.

The concept uses std::declval<Args>()... which produces rvalue references. If a callable has different noexcept specifications for lvalue vs rvalue arguments, this might not reflect all call site scenarios. This is likely acceptable for the library's use cases, but worth noting.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/core/concepts.cxx` around lines 188 - 191, The concept
noexcept_async_invocable currently uses std::declval<Args>()... which models
rvalue arguments only and can miss different noexcept specifications for lvalue
call sites; update the noexcept check to use lvalue references (e.g.
std::declval<std::add_lvalue_reference_t<Args>>()...) or otherwise test both
lvalue and rvalue categories so noexcept(async_invoke<Context,
Args...>(std::declval<Fn>(), ...)) reflects the call-site value category; modify
the noexcept expression in noexcept_async_invocable (and keep
async_invocable/async_invoke names intact) to use the chosen reference form.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@src/core/concepts.cxx`:
- Around line 188-191: The concept noexcept_async_invocable currently uses
std::declval<Args>()... which models rvalue arguments only and can miss
different noexcept specifications for lvalue call sites; update the noexcept
check to use lvalue references (e.g.
std::declval<std::add_lvalue_reference_t<Args>>()...) or otherwise test both
lvalue and rvalue categories so noexcept(async_invoke<Context,
Args...>(std::declval<Fn>(), ...)) reflects the call-site value category; modify
the noexcept expression in noexcept_async_invocable (and keep
async_invocable/async_invoke names intact) to use the chosen reference form.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 558a112f-eb94-4ad1-8048-f4f491601250

📥 Commits

Reviewing files that changed from the base of the PR and between 3939e6a and 931494a.

📒 Files selected for processing (4)
  • benchmark/src/libfork_benchmark/fib/lf_parts.cpp
  • src/core/concepts.cxx
  • src/core/promise.cxx
  • src/core/schedule.cxx

@ConorWilliams ConorWilliams merged commit d4e787f into modules Apr 1, 2026
10 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.

1 participant