Skip to content

GH-55429: [C++] std::invocable in codegen_internal.h fails to compile with CRAN's macOS 11.3 SDK - #55457

Merged
thisisnic merged 4 commits into
apache:mainfrom
thisisnic:GH-55429-std-invocable-cran-sdk
Nov 9, 2026
Merged

thisisnic merged 4 commits into
apache:mainfrom
thisisnic:GH-55429-std-invocable-cran-sdk

Conversation

@thisisnic

@thisisnic thisisnic commented Nov 9, 2026 •

Copy link
Copy Markdown
Member

Rationale for this change

macOS on CRAN is old and doesn't have all the C++20 stuff in it - evidenced by failing CI

What changes are included in this PR?

Refactor code which requires newer stuff that the CRAN stuff doesn't have

Are these changes tested?

Will run CI

Are there any user-facing changes?

Nah

Was AI used for this PR?

Yeah, all generated but I checked it with an adversarial review and will run CI to make sure it actually works

PR code and description written by:

  • Human
  • AI

Reviewed before submission by:

  • Human
  • AI
  • Not reviewed

Copilot AI balanced review requested due to automatic review settings November 9, 2026 15:49
@thisisnic

Copy link
Copy Markdown
Member Author

@github-actions crossbow submit test-r-macos-as-cran

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown

⚠️ GitHub issue #55429 has been automatically assigned in GitHub to PR creator.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The review reports no active issues with the macOS SDK compatibility changes.

No open issues 🎉

What changed in this PR

This PR addresses C++ build compatibility with CRAN’s macOS 11.3 SDK by replacing unavailable standard-library features with older equivalents.

Changes:

  • Replace std::invocable constraints with std::is_invocable_v in compute kernel generation.
  • Replace std::in_range checks with an integer-capacity trait and add compile-time assertions for representative type pairs.
File Description
cpp/​src/​parquet/​column_reader.cc Use numeric limits and signedness to check integer capacity without std::in_range.
cpp/​src/​arrow/​compute/​kernels/​codegen_internal.h Use std::is_invocable_v and remove the <concepts> include.

Review effort: Balanced

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown

Revision: cc05f47

Submitted crossbow builds: ursacomputing/crossbow @ actions-fd168d079e

Task Status
test-r-macos-as-cran GitHub Actions

Comment thread cpp/src/parquet/column_reader.cc Resolved
@pitrou pitrou added the CI: Extra: C++ Run extra C++ CI label Nov 9, 2026
Co-authored-by: Antoine Pitrou <pitrou@free.fr>
Copilot AI balanced review requested due to automatic review settings November 9, 2026 16:50
@thisisnic

Copy link
Copy Markdown
Member Author

CI failures looked unrelated but it's all running again since I accept the changes suggested

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues block the C++ compatibility changes targeting CRAN’s macOS 11.3 SDK.

No open issues 🎉

Review effort: Balanced

@thisisnic
thisisnic merged commit ca6ab6f into apache:main Nov 9, 2026
64 of 69 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants