aboutsummaryrefslogtreecommitdiff
path: root/include/gsl/gsl_util
diff options
context:
space:
mode:
Diffstat (limited to 'include/gsl/gsl_util')
-rw-r--r--include/gsl/gsl_util4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/gsl/gsl_util b/include/gsl/gsl_util
index 40e2229..eee63e7 100644
--- a/include/gsl/gsl_util
+++ b/include/gsl/gsl_util
@@ -48,7 +48,7 @@ template <class F>
class final_action
{
public:
- explicit final_action(F f) noexcept : f_(std::move(f)), invoke_(true) {}
+ explicit final_action(F f) noexcept : f_(std::move(f)) {}
final_action(final_action&& other) noexcept : f_(std::move(other.f_)), invoke_(other.invoke_)
{
@@ -65,7 +65,7 @@ public:
private:
F f_;
- bool invoke_;
+ bool invoke_ {true};
};
// finally() - convenience function to generate a final_action