Skip to content

simplify the STDEXEC_EXPLICIT_THIS_(BEGIN|END) macros - #2460

Open
ericniebler wants to merge 1 commit into
NVIDIA:mainfrom
ericniebler:simplify-explicit-this-portability-macros
Open

ericniebler wants to merge 1 commit into
NVIDIA:mainfrom
ericniebler:simplify-explicit-this-portability-macros

Conversation

@ericniebler

Copy link
Copy Markdown
Collaborator

i learned recently that the C++ grammar allows function declarations where the return type precedes a static declarator; e.g., auto static fun(args...) -> ret. that fact makes it possible to simplify the STDEXEC_EXPLICIT_THIS_(BEGIN|END) macros.

usage changes from:

 template <class Self>
 STDEXEC_EXPLICIT_THIS_BEGIN(auto fun)(this Self&& self, ...) { ... }
 STDEXEC_EXPLICIT_THIS_END(fun)

to:

 template <class Self>
 auto STDEXEC_EXPLICIT_THIS_BEGIN(fun)(this Self&& self, ...) { ... }
 STDEXEC_EXPLICIT_THIS_END(fun)

This branch has not been deployed

No deployments
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