From 307fc87b87754b218e1139919a4e2b48eec0de00 Mon Sep 17 00:00:00 2001 From: Nana Sakisaka <1901813+saki7@users.noreply.github.com> Date: Wed, 12 Aug 2026 19:25:24 +0900 Subject: [PATCH 1/7] Update GCC/Clang from 14/21 to 15/22 fixes #59 --- .github/workflows/ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 00bb93e..b88376c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,7 +46,7 @@ jobs: matrix: os: - name: ubuntu - version: 24.04 + version: 26.04 - name: windows version: 2025-vs2026 build_type: @@ -62,13 +62,13 @@ jobs: compiler: - name: GCC toolset: gcc - version: 14 - executable: g++-14 + version: 15 + executable: g++-15 cxxflags: -fdiagnostics-color=always - name: Clang toolset: clang - version: 21 - executable: clang++-21 + version: 22 + executable: clang++-22 cxxflags: -stdlib=libc++ -fcolor-diagnostics - name: MSVC toolset: msvc From d2fb315e1be0140e97229d0ab7b634b6ffba139d Mon Sep 17 00:00:00 2001 From: Nana Sakisaka <1901813+saki7@users.noreply.github.com> Date: Wed, 12 Aug 2026 19:52:21 +0900 Subject: [PATCH 2/7] Fix typo --- include/iris/colorize_format.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/iris/colorize_format.hpp b/include/iris/colorize_format.hpp index 9f49540..e98dec1 100644 --- a/include/iris/colorize_format.hpp +++ b/include/iris/colorize_format.hpp @@ -957,7 +957,7 @@ struct basic_colorized_format_string } #if __cpp_lib_format >= 202311L - explicit constexpr basic_colorize_format_string(detail::basic_dynamic_colorized_format_string dynamic_str) + explicit constexpr basic_colorized_format_string(detail::basic_dynamic_colorized_format_string dynamic_str) : fmt_(std::runtime_format(dynamic_str.str_)) { } @@ -1021,10 +1021,10 @@ dynamic_colorize(std::string_view str) #if __cpp_lib_format >= 202311L template -[[nodiscard]] constexpr detail::dynamic_colorize_format_string +[[nodiscard]] constexpr detail::dynamic_colorized_format_string dynamic_colorize_format(std::string_view str) { - return detail::basic_dynamic_colorize_format_string{str}; + return detail::basic_dynamic_colorized_format_string{str}; } #endif From 0bd5020f915c247d513f8acff5ef1ba6b87fd6af Mon Sep 17 00:00:00 2001 From: Nana Sakisaka <1901813+saki7@users.noreply.github.com> Date: Wed, 12 Aug 2026 19:58:44 +0900 Subject: [PATCH 3/7] Update README --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index b42353d..5c3e1d4 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,9 @@ # iris Iris is a modern C++ library collection that provides a starting point for building various applications and libraries. + +### Supported Environments + +- C++23 and C++26 +- GCC 15 +- Clang 22 +- MSVC 2026 From 3a43ba8b61ee0ad272e2f38f3be71257ceabc4b3 Mon Sep 17 00:00:00 2001 From: Nana Sakisaka <1901813+saki7@users.noreply.github.com> Date: Wed, 12 Aug 2026 19:58:49 +0900 Subject: [PATCH 4/7] Limit native pack indexing to not be enabled on GCC 15 --- include/iris/type_traits.hpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/iris/type_traits.hpp b/include/iris/type_traits.hpp index 1b768e2..7400713 100644 --- a/include/iris/type_traits.hpp +++ b/include/iris/type_traits.hpp @@ -57,7 +57,9 @@ struct at_c; template using at_c_t = at_c::type; -#if __cpp_pack_indexing >= 202311L // has native pack indexing +// Has native pack indexing? +// Note: GCC 15 emits "sorry, unimplemented: mangling type pack index" +#if !(defined(__GNUC__) && !defined(__clang__) && __GNUC__ <= 15) && __cpp_pack_indexing >= 202311L # define IRIS_CORE_PACK_INDEXING(I, Ts_ellipsis) Ts_ellipsis[I] From a716242c9cf0e887ba6a06f262ed0eca9de9bab7 Mon Sep 17 00:00:00 2001 From: Nana Sakisaka <1901813+saki7@users.noreply.github.com> Date: Wed, 12 Aug 2026 20:06:59 +0900 Subject: [PATCH 5/7] Disable runtime format --- include/iris/colorize_format.hpp | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/include/iris/colorize_format.hpp b/include/iris/colorize_format.hpp index e98dec1..93d458b 100644 --- a/include/iris/colorize_format.hpp +++ b/include/iris/colorize_format.hpp @@ -35,6 +35,13 @@ # define IRIS_COLORIZE_HAS_STATIC 0 #endif +// should be __cpp_lib_format >= 202603L +// TODO: since 202603L, `runtime_format` has been renamed to +// `dynamic_format`; our codebase needs renaming too. However +// we lack decent compilers right now; making it practically +// untestable. +#define IRIS_HAS_DYNAMIC_FORMAT 0 + namespace iris { class colorize_error : public std::invalid_argument @@ -905,7 +912,7 @@ struct basic_dynamic_colorized_string using dynamic_colorized_string = basic_dynamic_colorized_string; -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT template struct basic_dynamic_colorized_format_string @@ -956,7 +963,7 @@ struct basic_colorized_format_string scanner.scan(); } -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT explicit constexpr basic_colorized_format_string(detail::basic_dynamic_colorized_format_string dynamic_str) : fmt_(std::runtime_format(dynamic_str.str_)) { @@ -1018,7 +1025,7 @@ dynamic_colorize(std::string_view str) return detail::basic_dynamic_colorized_string{str}; } -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT template [[nodiscard]] constexpr detail::dynamic_colorized_format_string @@ -1099,7 +1106,7 @@ constexpr Out colorize_format_to(Out out, static_colorized_string, Args&&.. template [[nodiscard]] constexpr std::string colorize_format(colorized_string_view str, Args&&... args) { -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT return std::format(std::runtime_format(ansi_colorize::colorize(str)), std::make_format_args(args...)); #else return std::vformat(ansi_colorize::colorize(str), std::make_format_args(args...)); @@ -1109,7 +1116,7 @@ template template [[nodiscard]] constexpr std::string colorize_format(colorize_config const& cfg, std::string_view str, Args&&... args) { -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT return std::format(std::runtime_format(ansi_colorize::colorize(colorized_string_view{str, &cfg}, &cfg)), std::make_format_args(args...)); #else return std::vformat(ansi_colorize::colorize(colorized_string_view{str, &cfg}, &cfg), std::make_format_args(args...)); @@ -1121,7 +1128,7 @@ template template Out, class... Args> constexpr Out colorize_format_to(Out out, colorized_string_view str, Args&&... args) { -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT return std::format_to(std::move(out), std::runtime_format(ansi_colorize::colorize(str)), args...); #else return std::vformat_to(std::move(out), ansi_colorize::colorize(str), std::make_format_args(args...)); @@ -1131,7 +1138,7 @@ constexpr Out colorize_format_to(Out out, colorized_string_view str, Args&&... a template Out, class... Args> constexpr Out colorize_format_to(Out out, colorize_config const& cfg, std::string_view str, Args&&... args) { -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT return std::format_to(std::move(out), std::runtime_format(ansi_colorize::colorize(colorized_string_view{str, &cfg}, &cfg)), args...); #else return std::vformat_to(std::move(out), ansi_colorize::colorize(colorized_string_view{str, &cfg}, &cfg), std::make_format_args(args...)); @@ -1166,7 +1173,7 @@ using ansi_colorize::static_colorized_string; using ansi_colorize::dynamic_colorize; -#if __cpp_lib_format >= 202311L +#if IRIS_HAS_DYNAMIC_FORMAT using ansi_colorize::dynamic_colorize_format; #endif From 6f4640db3ff677f337a84b660edcd3ab23dbeef5 Mon Sep 17 00:00:00 2001 From: Nana Sakisaka <1901813+saki7@users.noreply.github.com> Date: Wed, 12 Aug 2026 20:10:52 +0900 Subject: [PATCH 6/7] Bump Catch2 to v3.15.3 --- test/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index dcac8a3..7e51f7c 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -45,7 +45,7 @@ include(FetchContent) FetchContent_Declare( Catch2 GIT_REPOSITORY https://github.com/catchorg/Catch2 - GIT_TAG v3.12.0 + GIT_TAG v3.15.3 GIT_SHALLOW ON ) FetchContent_MakeAvailable(Catch2) From d03184385972383a46ceff5b2533ea34cdd2a425 Mon Sep 17 00:00:00 2001 From: Nana Sakisaka <1901813+saki7@users.noreply.github.com> Date: Wed, 12 Aug 2026 20:23:25 +0900 Subject: [PATCH 7/7] Get rid of `__COUNTER__` warning on Catch2 --- test/CMakeLists.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 7e51f7c..4e2b3e7 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -40,6 +40,7 @@ endif() set(CATCH_CONFIG_FAST_COMPILE ON) set(CATCH_CONFIG_NO_USE_BUILTIN_CONSTANT_P ON) set(CATCH_CONFIG_DISABLE_EXCEPTIONS ON) # disable default `catch(...)` to enable debugger +set(CATCH_CONFIG_COUNTER OFF) include(FetchContent) FetchContent_Declare( @@ -53,7 +54,11 @@ FetchContent_MakeAvailable(Catch2) set_target_properties(Catch2 PROPERTIES CXX_EXTENSIONS OFF) set_target_properties(Catch2 Catch2WithMain PROPERTIES FOLDER "_deps") -target_compile_definitions(Catch2 PUBLIC DO_NOT_USE_WMAIN) +target_compile_definitions( + Catch2 PUBLIC + DO_NOT_USE_WMAIN + CATCH_CONFIG_NO_COUNTER=1 +) if(MSVC) target_compile_options(Catch2 PRIVATE /wd6054)