mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-02 17:09:26 +02:00
Replace usage of std::uncaught_exception
* Update minimum MacOS version to 10.12 Sierra * Replace `std::uncaught_exception` with `std::uncaught_exceptions` Signed-off-by: Sol Fisher Romanoff <sol@solfisher.com> Reference-to: https://github.com/tenacityteam/tenacity/pull/481
This commit is contained in:
parent
4e877b8aed
commit
c51b450d6c
@ -66,7 +66,7 @@ cmake_policy( SET CMP0075 NEW )
|
|||||||
|
|
||||||
# Definitions that must happen before the project() command
|
# Definitions that must happen before the project() command
|
||||||
if( APPLE )
|
if( APPLE )
|
||||||
set( MIN_MACOS_VERSION 10.9 )
|
set( MIN_MACOS_VERSION 10.12 )
|
||||||
set( TARGET_MACOS_VERSION 10.13 )
|
set( TARGET_MACOS_VERSION 10.13 )
|
||||||
# Generate schema files
|
# Generate schema files
|
||||||
set( CMAKE_XCODE_GENERATE_SCHEME ON )
|
set( CMAKE_XCODE_GENERATE_SCHEME ON )
|
||||||
|
@ -211,7 +211,7 @@ R GuardedCall(
|
|||||||
// At this point, e is the "current" exception, but not "uncaught"
|
// At this point, e is the "current" exception, but not "uncaught"
|
||||||
// unless it was rethrown by handler. handler might also throw some
|
// unless it was rethrown by handler. handler might also throw some
|
||||||
// other exception object.
|
// other exception object.
|
||||||
if (!std::uncaught_exception()) {
|
if (std::uncaught_exceptions() == 0) {
|
||||||
auto pException = std::current_exception(); // This points to e
|
auto pException = std::current_exception(); // This points to e
|
||||||
wxTheApp->CallAfter( [=] { // capture pException by value
|
wxTheApp->CallAfter( [=] { // capture pException by value
|
||||||
try { std::rethrow_exception(pException); }
|
try { std::rethrow_exception(pException); }
|
||||||
|
@ -1527,7 +1527,7 @@ bool AUPImportFileHandle::AddSamples(const FilePath &blockFilename,
|
|||||||
|
|
||||||
// If we are unwinding for an exception, don't do another
|
// If we are unwinding for an exception, don't do another
|
||||||
// potentially throwing operation
|
// potentially throwing operation
|
||||||
if (!std::uncaught_exception())
|
if (std::uncaught_exceptions() == 0)
|
||||||
// If this does throw, let that propagate, don't guard the call
|
// If this does throw, let that propagate, don't guard the call
|
||||||
AddSilence(len);
|
AddSilence(len);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user