[llvm] [llvm][Support] Add ExponentialBackoff helper (PR #81206)

via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 8 16:00:49 PST 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff d6c2cbbc6513bd412b34f3bf70e21b5a363b2fd9 5d4b769588f9ea978ac72619fc47e985d7eaea8e -- llvm/include/llvm/Support/ExponentialBackoff.h llvm/lib/Support/ExponentialBackoff.cpp llvm/unittests/Support/ExponentialBackoffTest.cpp llvm/lib/Support/LockFileManager.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/llvm/unittests/Support/ExponentialBackoffTest.cpp b/llvm/unittests/Support/ExponentialBackoffTest.cpp
index 327c86c544..257604908b 100644
--- a/llvm/unittests/Support/ExponentialBackoffTest.cpp
+++ b/llvm/unittests/Support/ExponentialBackoffTest.cpp
@@ -20,7 +20,7 @@ TEST(ExponentialBackoffTest, Timeout) {
   // Use short enough times that this test runs quickly.
   ExponentialBackoff Backoff(100ms, 1ms, 10ms);
   do {
-  } while(Backoff.waitForNextAttempt());
+  } while (Backoff.waitForNextAttempt());
   auto Duration = std::chrono::steady_clock::now() - Start;
   EXPECT_GE(Duration, 100ms);
 }

``````````

</details>


https://github.com/llvm/llvm-project/pull/81206


More information about the llvm-commits mailing list