Skip to content

Compilation failures in C++20 due to removal of std::result_of #46

Closed
@IanLilleyT

Description

@IanLilleyT

I'm using asyncplusplus from a C++20 project and it's failing to compile because std::result_of was removed in C++20. I worked around this problem by replacing std::result_of with std::invoke_result in my fork. You can see the changes here: https://github.com/IanLilleyT/asyncplusplus/commit/1a9cbc504eb675e42524c44f9ecf46973574b257. I opened an issue instead of a PR because I'm not sure if this library wants to include C++17 code in its headers, even if it's behind a macro. Let me know if I should turn this into a PR or not.

The cmake code / comment is partly taken from: https://stackoverflow.com/a/60890947

Thanks for reading!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions