This commit is contained in:
Martin Hořeňovský 2024-01-15 14:13:53 +01:00
parent 597ce12b65
commit 05e10dfccc
No known key found for this signature in database
GPG Key ID: DE48307B8B0D381A
7 changed files with 32 additions and 32 deletions

View File

@ -33,7 +33,7 @@ if (CMAKE_BINARY_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
endif() endif()
project(Catch2 project(Catch2
VERSION 3.5.1 # CML version placeholder, don't delete VERSION 3.5.2 # CML version placeholder, don't delete
LANGUAGES CXX LANGUAGES CXX
# HOMEPAGE_URL is not supported until CMake version 3.12, which # HOMEPAGE_URL is not supported until CMake version 3.12, which
# we do not target yet. # we do not target yet.

View File

@ -2,6 +2,7 @@
# Release notes # Release notes
**Contents**<br> **Contents**<br>
[3.5.2](#352)<br>
[3.5.1](#351)<br> [3.5.1](#351)<br>
[3.5.0](#350)<br> [3.5.0](#350)<br>
[3.4.0](#340)<br> [3.4.0](#340)<br>
@ -59,6 +60,13 @@
[Even Older versions](#even-older-versions)<br> [Even Older versions](#even-older-versions)<br>
## 3.5.1
### Fixes
* Fixed `-Wsubobject-linkage` in the Console reporter (#2794)
* Fixed adding new CLI Options to lvalue parser using `|` (#2787)
## 3.5.1 ## 3.5.1
### Improvements ### Improvements

View File

@ -6,8 +6,8 @@
// SPDX-License-Identifier: BSL-1.0 // SPDX-License-Identifier: BSL-1.0
// Catch v3.5.1 // Catch v3.5.2
// Generated: 2023-12-31 15:10:55.864983 // Generated: 2024-01-15 14:06:36.675713
// ---------------------------------------------------------- // ----------------------------------------------------------
// This file is an amalgamation of multiple different files. // This file is an amalgamation of multiple different files.
// You probably shouldn't edit it directly. // You probably shouldn't edit it directly.
@ -187,21 +187,16 @@ namespace Catch {
double const* last, double const* last,
Estimator& estimator ) { Estimator& estimator ) {
auto n = static_cast<size_t>( last - first ); auto n = static_cast<size_t>( last - first );
std::uniform_int_distribution<decltype( n )> dist( 0, std::uniform_int_distribution<size_t> dist( 0, n - 1 );
n - 1 );
sample out; sample out;
out.reserve( resamples ); out.reserve( resamples );
// We allocate the vector outside the loop to avoid realloc
// per resample
std::vector<double> resampled; std::vector<double> resampled;
resampled.reserve( n ); resampled.reserve( n );
for ( size_t i = 0; i < resamples; ++i ) { for ( size_t i = 0; i < resamples; ++i ) {
resampled.clear(); resampled.clear();
for ( size_t s = 0; s < n; ++s ) { for ( size_t s = 0; s < n; ++s ) {
resampled.push_back( resampled.push_back( first[dist( rng )] );
first[static_cast<std::ptrdiff_t>(
dist( rng ) )] );
} }
const auto estimate = const auto estimate =
estimator( resampled.data(), resampled.data() + resampled.size() ); estimator( resampled.data(), resampled.data() + resampled.size() );
@ -2273,7 +2268,7 @@ namespace Catch {
} }
Version const& libraryVersion() { Version const& libraryVersion() {
static Version version( 3, 5, 1, "", 0 ); static Version version( 3, 5, 2, "", 0 );
return version; return version;
} }
@ -4380,7 +4375,6 @@ namespace Detail {
CATCH_ENFORCE( !m_ofs.fail(), "Unable to open file: '" << filename << '\'' ); CATCH_ENFORCE( !m_ofs.fail(), "Unable to open file: '" << filename << '\'' );
m_ofs << std::unitbuf; m_ofs << std::unitbuf;
} }
~FileStream() override = default;
public: // IStream public: // IStream
std::ostream& stream() override { std::ostream& stream() override {
return m_ofs; return m_ofs;
@ -4395,7 +4389,6 @@ namespace Detail {
// Store the streambuf from cout up-front because // Store the streambuf from cout up-front because
// cout may get redirected when running tests // cout may get redirected when running tests
CoutStream() : m_os( Catch::cout().rdbuf() ) {} CoutStream() : m_os( Catch::cout().rdbuf() ) {}
~CoutStream() override = default;
public: // IStream public: // IStream
std::ostream& stream() override { return m_os; } std::ostream& stream() override { return m_os; }
@ -4409,7 +4402,6 @@ namespace Detail {
// Store the streambuf from cerr up-front because // Store the streambuf from cerr up-front because
// cout may get redirected when running tests // cout may get redirected when running tests
CerrStream(): m_os( Catch::cerr().rdbuf() ) {} CerrStream(): m_os( Catch::cerr().rdbuf() ) {}
~CerrStream() override = default;
public: // IStream public: // IStream
std::ostream& stream() override { return m_os; } std::ostream& stream() override { return m_os; }
@ -4427,8 +4419,6 @@ namespace Detail {
m_os( m_streamBuf.get() ) m_os( m_streamBuf.get() )
{} {}
~DebugOutStream() override = default;
public: // IStream public: // IStream
std::ostream& stream() override { return m_os; } std::ostream& stream() override { return m_os; }
}; };
@ -5441,7 +5431,6 @@ namespace Catch {
TrackerContext& ctx, TrackerContext& ctx,
ITracker* parent ): ITracker* parent ):
TrackerBase( CATCH_MOVE( nameAndLocation ), ctx, parent ) {} TrackerBase( CATCH_MOVE( nameAndLocation ), ctx, parent ) {}
~GeneratorTracker() override = default;
static GeneratorTracker* static GeneratorTracker*
acquire( TrackerContext& ctx, acquire( TrackerContext& ctx,
@ -8799,13 +8788,6 @@ findMax( std::size_t& i, std::size_t& j, std::size_t& k, std::size_t& l ) {
return l; return l;
} }
enum class Justification { Left, Right };
struct ColumnInfo {
std::string name;
std::size_t width;
Justification justification;
};
struct ColumnBreak {}; struct ColumnBreak {};
struct RowBreak {}; struct RowBreak {};
struct OutputFlush {}; struct OutputFlush {};
@ -8883,6 +8865,14 @@ public:
}; };
} // end anon namespace } // end anon namespace
enum class Justification { Left, Right };
struct ColumnInfo {
std::string name;
std::size_t width;
Justification justification;
};
class TablePrinter { class TablePrinter {
std::ostream& m_os; std::ostream& m_os;
std::vector<ColumnInfo> m_columnInfos; std::vector<ColumnInfo> m_columnInfos;

View File

@ -6,8 +6,8 @@
// SPDX-License-Identifier: BSL-1.0 // SPDX-License-Identifier: BSL-1.0
// Catch v3.5.1 // Catch v3.5.2
// Generated: 2023-12-31 15:10:53.044176 // Generated: 2024-01-15 14:06:34.036475
// ---------------------------------------------------------- // ----------------------------------------------------------
// This file is an amalgamation of multiple different files. // This file is an amalgamation of multiple different files.
// You probably shouldn't edit it directly. // You probably shouldn't edit it directly.
@ -3766,7 +3766,7 @@ namespace Catch {
bool benchmarkNoAnalysis = false; bool benchmarkNoAnalysis = false;
unsigned int benchmarkSamples = 100; unsigned int benchmarkSamples = 100;
double benchmarkConfidenceInterval = 0.95; double benchmarkConfidenceInterval = 0.95;
unsigned int benchmarkResamples = 100000; unsigned int benchmarkResamples = 100'000;
std::chrono::milliseconds::rep benchmarkWarmupTime = 100; std::chrono::milliseconds::rep benchmarkWarmupTime = 100;
Verbosity verbosity = Verbosity::Normal; Verbosity verbosity = Verbosity::Normal;
@ -4825,7 +4825,9 @@ namespace Catch {
template <typename T> template <typename T>
friend Parser operator|( Parser const& p, T&& rhs ) { friend Parser operator|( Parser const& p, T&& rhs ) {
return Parser( p ) |= CATCH_FORWARD(rhs); Parser temp( p );
temp |= rhs;
return temp;
} }
template <typename T> template <typename T>
@ -7146,7 +7148,7 @@ namespace Catch {
#define CATCH_VERSION_MAJOR 3 #define CATCH_VERSION_MAJOR 3
#define CATCH_VERSION_MINOR 5 #define CATCH_VERSION_MINOR 5
#define CATCH_VERSION_PATCH 1 #define CATCH_VERSION_PATCH 2
#endif // CATCH_VERSION_MACROS_HPP_INCLUDED #endif // CATCH_VERSION_MACROS_HPP_INCLUDED

View File

@ -8,7 +8,7 @@
project( project(
'catch2', 'catch2',
'cpp', 'cpp',
version: '3.5.1', # CML version placeholder, don't delete version: '3.5.2', # CML version placeholder, don't delete
license: 'BSL-1.0', license: 'BSL-1.0',
meson_version: '>=0.54.1', meson_version: '>=0.54.1',
) )

View File

@ -36,7 +36,7 @@ namespace Catch {
} }
Version const& libraryVersion() { Version const& libraryVersion() {
static Version version( 3, 5, 1, "", 0 ); static Version version( 3, 5, 2, "", 0 );
return version; return version;
} }

View File

@ -10,6 +10,6 @@
#define CATCH_VERSION_MAJOR 3 #define CATCH_VERSION_MAJOR 3
#define CATCH_VERSION_MINOR 5 #define CATCH_VERSION_MINOR 5
#define CATCH_VERSION_PATCH 1 #define CATCH_VERSION_PATCH 2
#endif // CATCH_VERSION_MACROS_HPP_INCLUDED #endif // CATCH_VERSION_MACROS_HPP_INCLUDED