Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[async_scope] __future_opstate touches incomplete __future_state members when STDEXEC_ENABLE_EXTRA_TYPE_CHECKING=ON

Open
#2,272 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
74/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
cpp
Domain
backend

Research direction

Start with include/exec/async_scope.hpp and inspect how __future_opstate accesses the incomplete __future_state. Configure and build test/test_type_async_scope.cpp with STDEXEC_ENABLE_EXTRA_TYPE_CHECKING=1 to reproduce the failure. Done means the async_scope test builds successfully on pristine main with the flag enabled.

Written by the indexing model from the issue text.

Description

Requested by @ericniebler in #2271 — follow-up found while verifying that PR with -DSTDEXEC_ENABLE_EXTRA_TYPE_CHECKING=ON. Fails on pristine main, so it is separate from the fix in #2271.

Description

With -DSTDEXEC_ENABLE_EXTRA_TYPE_CHECKING=ON, building test/test_type_async_scope.cpp fails in include/exec/async_scope.hpp: __future_opstate accesses members of __future_state while that type is still incomplete. The debug machinery forces earlier instantiation of queries/members than a normal build does, exposing the incomplete type.

Reproduction

Configure/build the async_scope tests with the flag enabled (e.g. a TU including exec/async_scope.hpp compiled with -DSTDEXEC_ENABLE_EXTRA_TYPE_CHECKING=1). Reproduces on pristine main.

Suggested fix direction

Forward-declare what __future_opstate needs, or move the accessed members into a base class defined before __future_opstate, so the debug build's earlier instantiation point is valid.

Dominant language
C++
Stars
2.4k
Forks
270
Avg merge
2d 17h
Merged PRs (30d)
37

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from NVIDIA/stdexec

All issues in NVIDIA/stdexec

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.