ci: enable clang-tidy in macOS job, use nullptr #262

pull Sjors wants to merge 2 commits into bitcoin-core:master from Sjors:2026/03/null changing 4 files +5 −4
  1. Sjors commented at 2:49 pm on March 20, 2026: member

    The first commit reproduces #261:

    0/Users/runner/work/libmultiprocess/libmultiprocess/src/mp/util.cpp:84:25: error: use nullptr [modernize-use-nullptr,-warnings-as-errors]
    1   84 |     pthread_threadid_np(NULL, &tid);
    2      |                         ^~~~
    3      |                         nullptr
    42 warnings generated.
    5Suppressed 1 warnings (1 in non-user code).
    6Use -header-filter=.* or leave it as default to display errors from all non-system headers. Use -system-headers to display errors from system headers as well.
    71 warning treated as error
    

    https://github.com/bitcoin-core/libmultiprocess/actions/runs/23348264051/job/67919536711?pr=262

    Using clang-tidy in the macOS job increases the runtime from ~1 minute to 2.5 minutes, which shouldn’t be a problem.

    The second commit fixes it.

  2. ci: enable clang-tidy in macOS job f499e37850
  3. mp: use nullptr with pthread_threadid_np a9499fad75
  4. DrahtBot commented at 2:49 pm on March 20, 2026: none

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK pinheadmz, ryanofsky

    If your review is incorrectly listed, please copy-paste <!–meta-tag:bot-skip–> into the comment that the bot should ignore.

  5. Sjors renamed this:
    ci: enable clang-tidy in macOS job
    ci: enable clang-tidy in macOS job, use nullptr
    on Mar 20, 2026
  6. Sjors marked this as ready for review on Mar 20, 2026
  7. pinheadmz commented at 3:17 pm on March 20, 2026: none

    concept ACK, will test locally later today.

    TIL DMP_ENABLE_CLANG_TIDY is a cmake option. Does that work in bitcoin core as well?

  8. hebasto commented at 3:42 pm on March 20, 2026: member

    TIL DMP_ENABLE_CLANG_TIDY is a cmake option.

    To be pedantic, the variable name is MP_ENABLE_CLANG_TIDY, and -D is a CMake option to set a variable.

  9. pinheadmz commented at 11:53 am on March 21, 2026: none

    ACK a9499fad755f01e7ceab0954045142cae4b6f9da

    Tested on macos by updating bitcoin core subtree to this commit. Ran unit, functional tests and clang tidy. Played with multiprocess binaries, all good. 👍

  10. ryanofsky approved
  11. ryanofsky commented at 7:07 pm on March 23, 2026: collaborator
    Code review ACK a9499fad755f01e7ceab0954045142cae4b6f9da. Nice change and coverage improvment
  12. ryanofsky commented at 7:14 pm on March 23, 2026: collaborator

    TIL DMP_ENABLE_CLANG_TIDY is a cmake option. Does that work in bitcoin core as well?

    I think specifying it with bitcoin core will only enable clang-tidy for libmultiprocess code, but you might be able to get similar behavior for bitcoin core by setting -DCMAKE_CXX_CLANG_TIDY=clang-tidy directly. Downside of using these options is they can noticeably slow down the build though.

  13. ryanofsky merged this on Mar 23, 2026
  14. ryanofsky closed this on Mar 23, 2026

  15. Sjors deleted the branch on Mar 24, 2026

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin-core/libmultiprocess. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-03-29 21:30 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me