From 2ad116a9d3297e87e7f6afcb77fbf3dd5d13ff06 Mon Sep 17 00:00:00 2001 From: Jarryd Beck Date: Mon, 15 Jul 2024 17:09:12 +1000 Subject: [PATCH] Update catch header Fixes #435. Updates catch header to fix include error on MacOS. --- test/catch.hpp | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/test/catch.hpp b/test/catch.hpp index 9b309bdd..514d8c84 100644 --- a/test/catch.hpp +++ b/test/catch.hpp @@ -1,9 +1,9 @@ /* - * Catch v2.13.10 - * Generated: 2022-10-16 11:01:23.452308 + * Catch v2.13.11 + * Generated: 2024-07-15 17:08:27.065263 * ---------------------------------------------------------- * This file has been merged from multiple headers. Please don't edit it directly - * Copyright (c) 2022 Two Blue Cubes Ltd. All rights reserved. + * Copyright (c) 2024 Two Blue Cubes Ltd. All rights reserved. * * Distributed under the Boost Software License, Version 1.0. (See accompanying * file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -15,7 +15,7 @@ #define CATCH_VERSION_MAJOR 2 #define CATCH_VERSION_MINOR 13 -#define CATCH_VERSION_PATCH 10 +#define CATCH_VERSION_PATCH 11 #ifdef __clang__ # pragma clang system_header @@ -69,6 +69,9 @@ // See e.g.: // https://opensource.apple.com/source/CarbonHeaders/CarbonHeaders-18.1/TargetConditionals.h.auto.html #ifdef __APPLE__ +# ifndef __has_extension +# define __has_extension(x) 0 +# endif # include # if (defined(TARGET_OS_OSX) && TARGET_OS_OSX == 1) || \ (defined(TARGET_OS_MAC) && TARGET_OS_MAC == 1) @@ -2707,7 +2710,7 @@ namespace Catch { INTERNAL_CATCH_TRY { \ CATCH_INTERNAL_START_WARNINGS_SUPPRESSION \ CATCH_INTERNAL_SUPPRESS_PARENTHESES_WARNINGS \ - catchAssertionHandler.handleExpr( Catch::Decomposer() <= __VA_ARGS__ ); \ + catchAssertionHandler.handleExpr( Catch::Decomposer() <= __VA_ARGS__ ); /* NOLINT(bugprone-chained-comparison) */ \ CATCH_INTERNAL_STOP_WARNINGS_SUPPRESSION \ } INTERNAL_CATCH_CATCH( catchAssertionHandler ) \ INTERNAL_CATCH_REACT( catchAssertionHandler ) \ @@ -10171,7 +10174,10 @@ namespace { #elif defined( CATCH_CONFIG_COLOUR_ANSI ) ////////////////////////////////////// -#include +#if defined( CATCH_PLATFORM_LINUX ) || defined( CATCH_PLATFORM_MAC ) +# define CATCH_INTERNAL_HAS_ISATTY +# include +#endif namespace Catch { namespace { @@ -10220,7 +10226,8 @@ namespace { #if defined(CATCH_PLATFORM_MAC) || defined(CATCH_PLATFORM_IPHONE) !isDebuggerActive() && #endif -#if !(defined(__DJGPP__) && defined(__STRICT_ANSI__)) +#if defined( CATCH_INTERNAL_HAS_ISATTY ) && \ + !( defined( __DJGPP__ ) && defined( __STRICT_ANSI__ ) ) isatty(STDOUT_FILENO) #else false @@ -15389,7 +15396,7 @@ namespace Catch { } Version const& libraryVersion() { - static Version version( 2, 13, 10, "", 0 ); + static Version version( 2, 13, 11, "", 0 ); return version; }