From 271f6abe708d8d03872a4a8d645cca6ac84952a3 Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Mon, 29 Sep 2025 09:56:43 -0600 Subject: [PATCH 1/8] fix: update conditional static assertion There is a static assertion that spuriously fails on MSVC that was version checked. Unfortunately it fires every time there is a new compiler update, so for now we will remove the version check and add it back once the compiler bug is fixed. --- tests/span_tests.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/span_tests.cpp b/tests/span_tests.cpp index e41026e71..9b74ad447 100644 --- a/tests/span_tests.cpp +++ b/tests/span_tests.cpp @@ -412,8 +412,8 @@ TEST(span_test, from_std_array_constructor) static_assert(!CtorCompilesFor, std::array&>, "!CtorCompilesFor, std::array&>"); -#if !defined(_MSC_VER) || (_MSC_VER > 1943) || (__cplusplus >= 201703L) - // Fails on "Visual Studio 16 2019/Visual Studio 17 2022, windows-2019/2022, Debug/Release, 14". +#if !defined(_MSC_VER) || (__cplusplus >= 201703L) + // Fails on MSVC. TODO: report a feedback bug. static_assert(!ConversionCompilesFor, std::array>, "!ConversionCompilesFor, std::array>"); #endif @@ -529,8 +529,8 @@ TEST(span_test, from_container_constructor) EXPECT_TRUE(cs.data() == cstr.data()); } -#if !defined(_MSC_VER) || (_MSC_VER > 1943) || (__cplusplus >= 201703L) - // Fails on "Visual Studio 16 2019/Visual Studio 17 2022, windows-2019/2022, Debug/Release, 14". +#if !defined(_MSC_VER) || (__cplusplus >= 201703L) + // Fails on MSVC. TODO: report a feedback bug. static_assert(!ConversionCompilesFor, std::vector>, "!ConversionCompilesFor, std::vector>"); #endif // !defined(_MSC_VER) || (_MSC_VER > 1942) || (__cplusplus >= 201703L) From 69a46a22486980f1dceb6e46a720dade8ac106c8 Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Mon, 29 Sep 2025 10:19:48 -0600 Subject: [PATCH 2/8] fix: ios pipeline failure Looks like somewhere along the line, the iOS simulator changed the range of support iOS versions. This changes bumps the version from 9 to 12.0. Also noticed that the GSL OSX bundle version was quite out of date. I bumped this from 3.1.0 to 4.2.0 and created an upgrade checklist file in docs/ so we don't forget these types of tasks in the future. --- .github/workflows/ios.yml | 6 +++--- docs/upgrade_checklist.md | 19 +++++++++++++++++++ 2 files changed, 22 insertions(+), 3 deletions(-) create mode 100644 docs/upgrade_checklist.md diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml index a7f2f104f..b5251df25 100644 --- a/.github/workflows/ios.yml +++ b/.github/workflows/ios.yml @@ -25,11 +25,11 @@ jobs: -GXcode \ -DCMAKE_SYSTEM_NAME=iOS \ "-DCMAKE_OSX_ARCHITECTURES=arm64;x86_64" \ - -DCMAKE_OSX_DEPLOYMENT_TARGET=9 \ + -DCMAKE_OSX_DEPLOYMENT_TARGET=12.0 \ -DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY \ "-DMACOSX_BUNDLE_GUI_IDENTIFIER=GSL.\$(EXECUTABLE_NAME)" \ - -DMACOSX_BUNDLE_BUNDLE_VERSION=3.1.0 \ - -DMACOSX_BUNDLE_SHORT_VERSION_STRING=3.1.0 \ + -DMACOSX_BUNDLE_BUNDLE_VERSION=4.2.0 \ + -DMACOSX_BUNDLE_SHORT_VERSION_STRING=4.2.0 \ .. - name: Build diff --git a/docs/upgrade_checklist.md b/docs/upgrade_checklist.md new file mode 100644 index 000000000..a32e90af1 --- /dev/null +++ b/docs/upgrade_checklist.md @@ -0,0 +1,19 @@ +> When bumping the version, you need to update the following files: + +1. [ ] [../CMakeLists.txt]() Bump `GSL_VERSION` +1. [ ] [../README.md]() Bump `GIT_TAG` +1. [ ] [../.github/workflows/ios.yml]() Bump `MACOSX_BUNDLE_BUNDLE_VERSION` and +`MACOSX_BUNDLE_SHORT_VERSION_STRING` + +> After updating, you need to create a new GitHub release: + +1. [ ] [https://github.com/microsoft/GSL/releases/new]() + +Be sure to update the release notes accordingly and properly mention open-source +contributors. + +> After a new release exists, update the `ms-gsl` vcpkg port: + +1. [ ] [https://github.com/microsoft/vcpkg/tree/master/ports/ms-gsl]() + +Be sure to monitor the PR that updates the port for any feedback from vcpkg maintainers. From bfdf94670edab70b30feb00e233873ad46bb359c Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Mon, 29 Sep 2025 10:24:37 -0600 Subject: [PATCH 3/8] bump xcode version from 15.4 to 16.4 --- .github/workflows/compilers.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/compilers.yml b/.github/workflows/compilers.yml index 385758353..c892c43af 100644 --- a/.github/workflows/compilers.yml +++ b/.github/workflows/compilers.yml @@ -65,7 +65,7 @@ jobs: xcode: strategy: matrix: - xcode_version: [ '15.4' ] + xcode_version: [ '16.4' ] build_type: [ Debug, Release ] cxx_version: [ 14, 17, 20, 23 ] runs-on: macos-latest From 5ce7964004099a4e626c346a9856335249c6655c Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Mon, 29 Sep 2025 11:05:55 -0600 Subject: [PATCH 4/8] fix compiler warning when building gtest for ios --- .github/workflows/compilers.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/compilers.yml b/.github/workflows/compilers.yml index c892c43af..c6f8ac86d 100644 --- a/.github/workflows/compilers.yml +++ b/.github/workflows/compilers.yml @@ -81,6 +81,7 @@ jobs: cmake_build_type: ${{ matrix.build_type }} cmake_cxx_compiler: clang++ gsl_cxx_standard: ${{ matrix.cxx_version }} + extra_cmake_args: '-DCMAKE_CXX_FLAGS="-isysroot \"$(xcode-select --print-path)/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk\""' VisualStudio: strategy: From ed516e2272bddb397f4b084049f24995992b0c5d Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Mon, 29 Sep 2025 11:24:38 -0600 Subject: [PATCH 5/8] allow for missing include dirs on command line --- .github/workflows/ios.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml index b5251df25..56567258d 100644 --- a/.github/workflows/ios.yml +++ b/.github/workflows/ios.yml @@ -30,6 +30,7 @@ jobs: "-DMACOSX_BUNDLE_GUI_IDENTIFIER=GSL.\$(EXECUTABLE_NAME)" \ -DMACOSX_BUNDLE_BUNDLE_VERSION=4.2.0 \ -DMACOSX_BUNDLE_SHORT_VERSION_STRING=4.2.0 \ + -DCMAKE_CXX_FLAGS="-Wno-missing-include-dirs" \ .. - name: Build From e91d455efb7720dc5bacf174a44e58d8638bf3b2 Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Mon, 29 Sep 2025 11:41:02 -0600 Subject: [PATCH 6/8] replace windows-2019 with windows-2025 --- .github/workflows/compilers.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/compilers.yml b/.github/workflows/compilers.yml index c6f8ac86d..eb2f9f9a4 100644 --- a/.github/workflows/compilers.yml +++ b/.github/workflows/compilers.yml @@ -87,7 +87,7 @@ jobs: strategy: matrix: generator: [ 'Visual Studio 16 2019', 'Visual Studio 17 2022' ] - image: [ windows-2019, windows-2022 ] + image: [ windows-2022, windows-2025 ] build_type: [ Debug, Release ] extra_args: [ '', '-T ClangCL' ] cxx_version: [ 14, 17, 20, 23 ] From db6568b2a413e569eaed59ea32143dcbfd7f8cb1 Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Mon, 29 Sep 2025 11:52:10 -0600 Subject: [PATCH 7/8] update visual studio versions after runner bump --- .github/workflows/compilers.yml | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/.github/workflows/compilers.yml b/.github/workflows/compilers.yml index eb2f9f9a4..7ab2c7eaf 100644 --- a/.github/workflows/compilers.yml +++ b/.github/workflows/compilers.yml @@ -86,18 +86,11 @@ jobs: VisualStudio: strategy: matrix: - generator: [ 'Visual Studio 16 2019', 'Visual Studio 17 2022' ] + generator: [ 'Visual Studio 17 2022' ] image: [ windows-2022, windows-2025 ] build_type: [ Debug, Release ] extra_args: [ '', '-T ClangCL' ] cxx_version: [ 14, 17, 20, 23 ] - exclude: - - generator: 'Visual Studio 17 2022' - image: windows-2019 - - generator: 'Visual Studio 16 2019' - image: windows-2022 - - generator: 'Visual Studio 16 2019' - cxx_version: 23 runs-on: ${{ matrix.image }} steps: - uses: actions/checkout@v4 From 2e65f547281fa66a16df539bd1f81b12da857e65 Mon Sep 17 00:00:00 2001 From: Carson Radtke Date: Tue, 30 Sep 2025 11:29:30 -0600 Subject: [PATCH 8/8] PR feedback: make sure markdown links are syntactically correct --- docs/upgrade_checklist.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/upgrade_checklist.md b/docs/upgrade_checklist.md index a32e90af1..bf923b3df 100644 --- a/docs/upgrade_checklist.md +++ b/docs/upgrade_checklist.md @@ -1,19 +1,19 @@ > When bumping the version, you need to update the following files: -1. [ ] [../CMakeLists.txt]() Bump `GSL_VERSION` -1. [ ] [../README.md]() Bump `GIT_TAG` -1. [ ] [../.github/workflows/ios.yml]() Bump `MACOSX_BUNDLE_BUNDLE_VERSION` and +1. [ ] [CMakeLists.txt](../CMakeLists.txt) Bump `GSL_VERSION` +1. [ ] [README.md](../README.md) Bump `GIT_TAG` +1. [ ] [ios.yml](../.github/workflows/ios.yml) Bump `MACOSX_BUNDLE_BUNDLE_VERSION` and `MACOSX_BUNDLE_SHORT_VERSION_STRING` > After updating, you need to create a new GitHub release: -1. [ ] [https://github.com/microsoft/GSL/releases/new]() +1. [ ] [Microsoft/GSL - Create Release](https://github.com/microsoft/GSL/releases/new) Be sure to update the release notes accordingly and properly mention open-source contributors. > After a new release exists, update the `ms-gsl` vcpkg port: -1. [ ] [https://github.com/microsoft/vcpkg/tree/master/ports/ms-gsl]() +1. [ ] [Microsoft/vcpkg - ms-gsl port](https://github.com/microsoft/vcpkg/tree/master/ports/ms-gsl) Be sure to monitor the PR that updates the port for any feedback from vcpkg maintainers.