Skip to content

Conversation

@spoonincode
Copy link
Contributor

This removes the is_callable_v workaround and replaces it with std::is_invocable_v as the workaround is causing a

template argument for non-type template parameter must be an expression

error on clang12. Fixes clang12 and also is compiling on gcc8, clang6, and XCode 10.2 -- pretty much the bare minimum for eosio. But, I'm not sure if it's desirable for eos-vm to support a wider range of compilers and the workaround should be fixed instead. Or if I've just completely missed the purpose of this code in the first place... so please review carefully.

@swatanabe
Copy link

is_invokable_v is wrong. is_callable_v is used here to distinguish (member) function pointers from function objects. OTOH, I have no idea how the is_callable_v ever worked, as clang is obviously correct to diagnose it as an error.

@spoonincode
Copy link
Contributor Author

It would be useful to add a unit test that exercises this code then, as far as I can remember all unit tests did pass with is_invocable_v

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.

3 participants