mirror of
https://github.com/KjellKod/g3log.git
synced 2024-12-13 10:42:56 +01:00
Resolve noexcept warnings on lambdas (#463)
When running with additional warnings enabled, a couple lambdas produce a warning that they should be declared with noexcept. This addresses the lambdas that had been identified while building. Signed-off-by: Ben Magistro <koncept1@gmail.com>
This commit is contained in:
parent
5adecb5ad9
commit
ed91b899f0
@ -48,7 +48,7 @@ namespace kjellkod {
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
virtual ~Active() {
|
virtual ~Active() {
|
||||||
send([this] { done_ = true;});
|
send([this]() noexcept { done_ = true;});
|
||||||
thd_.join();
|
thd_.join();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -127,7 +127,7 @@ namespace g3 {
|
|||||||
/// This will clear/remove all the sinks. If a sink shared_ptr was retrieved via the sink
|
/// This will clear/remove all the sinks. If a sink shared_ptr was retrieved via the sink
|
||||||
/// handle then the sink will be removed internally but will live on in the client's instance
|
/// handle then the sink will be removed internally but will live on in the client's instance
|
||||||
void removeAllSinks() {
|
void removeAllSinks() {
|
||||||
auto bg_clear_sink_call = [this] { _impl._sinks.clear(); };
|
auto bg_clear_sink_call = [this]() noexcept { _impl._sinks.clear(); };
|
||||||
auto token_cleared = g3::spawn_task(bg_clear_sink_call, _impl._bg.get());
|
auto token_cleared = g3::spawn_task(bg_clear_sink_call, _impl._bg.get());
|
||||||
token_cleared.wait();
|
token_cleared.wait();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user