From 98e36e442aba2b7d200c4448cc2acf690889b1bc Mon Sep 17 00:00:00 2001 From: Terraneo Federico <fede.tft@miosix.org> Date: Sun, 30 Apr 2023 12:32:37 +0200 Subject: [PATCH] Small changes to modernize code style --- miosix/e20/e20.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/miosix/e20/e20.h b/miosix/e20/e20.h index bafe6258..4ec62414 100644 --- a/miosix/e20/e20.h +++ b/miosix/e20/e20.h @@ -99,16 +99,17 @@ public: return events.empty(); } -private: - EventQueue(const EventQueue&); - EventQueue& operator= (const EventQueue&); + EventQueue(const EventQueue&) = delete; + EventQueue& operator= (const EventQueue&) = delete; +private: std::list<std::function<void ()>> events; ///< Event queue mutable FastMutex m; ///< Mutex for synchronisation ConditionVariable cv; ///< Condition variable for synchronisation }; /** + * \internal * This class is to extract from FixedEventQueue code that * does not depend on the NumSlots template parameters. */ @@ -427,10 +428,10 @@ public: return this->sizeImpl()==0; } -private: - FixedEventQueue(const FixedEventQueue&); - FixedEventQueue& operator= (const FixedEventQueue&); + FixedEventQueue(const FixedEventQueue&) = delete; + FixedEventQueue& operator= (const FixedEventQueue&) = delete; +private: Callback<SlotSize> events[NumSlots]; ///< Fixed size queue of events }; -- GitLab