Skip to content

Conversation

hnrklssn
Copy link
Contributor

@hnrklssn hnrklssn commented Oct 8, 2025

No description provided.

@hnrklssn
Copy link
Contributor Author

hnrklssn commented Oct 8, 2025

preset=buildbot_linux
@swift-ci please test with preset linux

@hnrklssn hnrklssn force-pushed the fix-std-span-linux branch from b7bcd95 to dd34be4 Compare October 8, 2025 22:40
@hnrklssn
Copy link
Contributor Author

hnrklssn commented Oct 8, 2025

preset=buildbot_linux
@swift-ci please test with preset linux

@hnrklssn
Copy link
Contributor Author

hnrklssn commented Oct 9, 2025

@swift-ci please test

…ailing-tests-harder"

This reverts commit 6541965, reversing
changes made to 5373530.
This adds a check in CMake for whether the current C++ stdlib contains
the 'span' header. If so, the llvm-lit feature 'std_span' is set. Also
adds 'REQUIRES: std_span' to interop tests that include 'span'. This
means we no longer have to choose between blanket disabling `std::span`
tests on all Linux distributions, or listing every Linux distro with a
libstdc++ version without `std::span` support as unsupported.

rdar://161999160
rdar://161999174
rdar://162106580
rdar://162106619
rdar://162106643
rdar://162106653
rdar://162106722
rdar://162106747
@hnrklssn
Copy link
Contributor Author

@swift-ci please smoke test

@hnrklssn hnrklssn requested a review from etcwilde October 10, 2025 05:04
endif()

include(CheckIncludeFileCXX)
check_include_file_cxx("span" HAVE_STD_SPAN)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@etcwilde @egorzhdan Could you check my logic here - is this approach sound? Or does this need to be checked for every test target? Is CMake aware of multiple different SDKs when testing multiple different targets?

Perhaps I'm overthinking it - I never use multiple test targets, so that feature is a bit outside my wheelhouse. I can't think of a case where we would realistically test against one target without std::span and one with, but I thought I'd highlight it.

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