node icon indicating copy to clipboard operation
node copied to clipboard

src: simplify is_callable by making it a concept

Open tniessen opened this issue 7 months ago • 1 comments

Using a C++20 concept here makes is_callable much simpler than relying on SFINAE. It is equivalent for function types, std::function, lambdas, and classes with operator(), regardless of argument or return types.

tniessen avatar May 04 '25 17:05 tniessen

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 90.14%. Comparing base (5fb879c) to head (33a9784). :warning: Report is 953 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #58169   +/-   ##
=======================================
  Coverage   90.13%   90.14%           
=======================================
  Files         630      630           
  Lines      186611   186611           
  Branches    36631    36634    +3     
=======================================
+ Hits       168204   168220   +16     
+ Misses      11192    11183    -9     
+ Partials     7215     7208    -7     
Files with missing lines Coverage Δ
src/req_wrap-inl.h 92.72% <ø> (ø)
src/util.h 91.22% <ø> (ø)

... and 25 files with indirect coverage changes

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar May 04 '25 18:05 codecov[bot]

CI: https://ci.nodejs.org/job/node-test-pull-request/68630/

nodejs-github-bot avatar Aug 14 '25 14:08 nodejs-github-bot

CI: https://ci.nodejs.org/job/node-test-pull-request/68825/

nodejs-github-bot avatar Aug 23 '25 11:08 nodejs-github-bot

CI: https://ci.nodejs.org/job/node-test-pull-request/69206/

nodejs-github-bot avatar Sep 12 '25 11:09 nodejs-github-bot

CI: https://ci.nodejs.org/job/node-test-pull-request/69284/

nodejs-github-bot avatar Sep 19 '25 10:09 nodejs-github-bot

Landed in f6d6b911fa3deb74e59f3cd9a5bb8dfecceabec4

nodejs-github-bot avatar Sep 20 '25 22:09 nodejs-github-bot