Ensure curly-braces around control-flow
[folly.git] / folly / futures / ManualExecutor.h
index d4fb8db6bb606e86b534a6704fca223dbbd58610..028a4ce63af03490c1b0d183cdf6ea725c9e6f2e 100644 (file)
  */
 
 #pragma once
-#include <folly/LifoSem.h>
-#include <folly/futures/DrivableExecutor.h>
-#include <folly/futures/ScheduledExecutor.h>
+
+#include <cstdio>
 #include <memory>
 #include <mutex>
 #include <queue>
-#include <cstdio>
+
+#include <folly/LifoSem.h>
+#include <folly/executors/DrivableExecutor.h>
+#include <folly/executors/ScheduledExecutor.h>
 
 namespace folly {
   /// A ManualExecutor only does work when you turn the crank, by calling
@@ -73,7 +75,7 @@ namespace folly {
 
     }
 
-    virtual void scheduleAt(Func&& f, TimePoint const& t) override {
+    void scheduleAt(Func&& f, TimePoint const& t) override {
       std::lock_guard<std::mutex> lock(lock_);
       scheduledFuncs_.emplace(t, std::move(f));
       sem_.post();
@@ -130,8 +132,9 @@ namespace folly {
       bool operator<(ScheduledFunc const& b) const {
         // Earlier-scheduled things must be *higher* priority
         // in the max-based std::priority_queue
-        if (time == b.time)
+        if (time == b.time) {
           return ordinal > b.ordinal;
+        }
         return time > b.time;
       }