From 182c8f8357739f905bbd721006480502435b6b43 Mon Sep 17 00:00:00 2001 From: rtk0c Date: Sun, 27 Nov 2022 12:04:31 -0800 Subject: Update brace style to match rest of my projects --- app/source/Cplt/Utils/ScopeGuard.hpp | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'app/source/Cplt/Utils/ScopeGuard.hpp') diff --git a/app/source/Cplt/Utils/ScopeGuard.hpp b/app/source/Cplt/Utils/ScopeGuard.hpp index f2b7f46..e7db2a4 100644 --- a/app/source/Cplt/Utils/ScopeGuard.hpp +++ b/app/source/Cplt/Utils/ScopeGuard.hpp @@ -5,8 +5,7 @@ #include template -class ScopeGuard -{ +class ScopeGuard { private: TCleanupFunc mFunc; bool mDismissed = false; @@ -19,19 +18,16 @@ public: /// would work. It is highly discourage and unlikely that one would want to use ScopeGuard as a function /// parameter, so the normal argument that implicit conversion are harmful doesn't really apply here. ScopeGuard(TCleanupFunc func) - : mFunc{ std::move(func) } - { + : mFunc{ std::move(func) } { } - ~ScopeGuard() - { + ~ScopeGuard() { if (!mDismissed) { mFunc(); } } - void Dismiss() noexcept - { + void Dismiss() noexcept { mDismissed = true; } }; -- cgit v1.2.3-70-g09d2