clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version.  The way clang-18
handles lambda formatting also changed, so we have made changes to the
organization default style format to better handle lambda formatting.

See I5e08687e696dd240402a2780158664b7113def0e for updated style.
See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement.

Change-Id: I4f63258febea27dae710c252033b9151e02be7e8
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/example/asio-example.cpp b/example/asio-example.cpp
index 08fcd11..f5f0176 100644
--- a/example/asio-example.cpp
+++ b/example/asio-example.cpp
@@ -59,10 +59,10 @@
 {
     boost::system::error_code ec;
     variant testValue;
-    conn->yield_method_call<>(yield, ec, "xyz.openbmc_project.asio-test",
-                              "/xyz/openbmc_project/test",
-                              "org.freedesktop.DBus.Properties", "Set",
-                              "xyz.openbmc_project.test", "int", variant(24));
+    conn->yield_method_call<>(
+        yield, ec, "xyz.openbmc_project.asio-test", "/xyz/openbmc_project/test",
+        "org.freedesktop.DBus.Properties", "Set", "xyz.openbmc_project.test",
+        "int", variant(24));
     testValue = conn->yield_method_call<variant>(
         yield, ec, "xyz.openbmc_project.asio-test", "/xyz/openbmc_project/test",
         "org.freedesktop.DBus.Properties", "Get", "xyz.openbmc_project.test",
@@ -217,26 +217,26 @@
     iface->register_property("lessThan50", 23,
                              // custom set
                              [](const int& req, int& propertyValue) {
-        if (req >= 50)
-        {
-            return false;
-        }
-        propertyValue = req;
-        return true;
-    });
+                                 if (req >= 50)
+                                 {
+                                     return false;
+                                 }
+                                 propertyValue = req;
+                                 return true;
+                             });
     iface->register_property(
         "TrailTime", std::string("foo"),
         // custom set
         [](const std::string& req, std::string& propertyValue) {
-        propertyValue = req;
-        return true;
-    },
+            propertyValue = req;
+            return true;
+        },
         // custom get
         [](const std::string& property) {
-        auto now = std::chrono::system_clock::now();
-        auto timePoint = std::chrono::system_clock::to_time_t(now);
-        return property + std::ctime(&timePoint);
-    });
+            auto now = std::chrono::system_clock::now();
+            auto timePoint = std::chrono::system_clock::to_time_t(now);
+            return property + std::ctime(&timePoint);
+        });
 
     // test method creation
     iface->register_method("TestMethod", [](const int32_t& callCount) {
@@ -250,8 +250,8 @@
     // so will be executed in coroutine context if called
     iface->register_method("TestYieldFunction",
                            [conn](boost::asio::yield_context yield, int val) {
-        return fooYield(yield, conn, val);
-    });
+                               return fooYield(yield, conn, val);
+                           });
 
     iface->register_method("TestMethodWithMessage", methodWithMessage);
 
@@ -297,10 +297,10 @@
     }
 
     // test async method call and async send
-    auto mesg = conn->new_method_call("xyz.openbmc_project.ObjectMapper",
-                                      "/xyz/openbmc_project/object_mapper",
-                                      "xyz.openbmc_project.ObjectMapper",
-                                      "GetSubTree");
+    auto mesg =
+        conn->new_method_call("xyz.openbmc_project.ObjectMapper",
+                              "/xyz/openbmc_project/object_mapper",
+                              "xyz.openbmc_project.ObjectMapper", "GetSubTree");
 
     int32_t depth = 2;
     constexpr std::array<std::string_view, 1> interfaces{
@@ -324,17 +324,17 @@
 
     conn->async_method_call(
         [](boost::system::error_code ec, GetSubTreeType& subtree) {
-        std::cout << "async_method_call callback\n";
-        if (ec)
-        {
-            std::cerr << "error with async_method_call\n";
-            return;
-        }
-        for (auto& item : subtree)
-        {
-            std::cout << item.first << "\n";
-        }
-    },
+            std::cout << "async_method_call callback\n";
+            if (ec)
+            {
+                std::cerr << "error with async_method_call\n";
+                return;
+            }
+            for (auto& item : subtree)
+            {
+                std::cout << item.first << "\n";
+            }
+        },
         "xyz.openbmc_project.ObjectMapper",
         "/xyz/openbmc_project/object_mapper",
         "xyz.openbmc_project.ObjectMapper", "GetSubTree",
@@ -345,17 +345,18 @@
         [nonConstCapture = std::move(nonConstCapture)](
             boost::system::error_code ec,
             const std::vector<std::string>& /*things*/) mutable {
-        std::cout << "async_method_call callback\n";
-        nonConstCapture += " stuff";
-        if (ec)
-        {
-            std::cerr << "async_method_call expected failure: " << ec << "\n";
-        }
-        else
-        {
-            std::cerr << "async_method_call should have failed!\n";
-        }
-    },
+            std::cout << "async_method_call callback\n";
+            nonConstCapture += " stuff";
+            if (ec)
+            {
+                std::cerr << "async_method_call expected failure: " << ec
+                          << "\n";
+            }
+            else
+            {
+                std::cerr << "async_method_call should have failed!\n";
+            }
+        },
         "xyz.openbmc_project.ObjectMapper",
         "/xyz/openbmc_project/object_mapper",
         "xyz.openbmc_project.ObjectMapper", "GetSubTree",
@@ -383,15 +384,15 @@
 
     conn->async_method_call(
         [](boost::system::error_code ec, int32_t testValue) {
-        if (ec)
-        {
-            std::cerr << "TestYieldFunction returned error with "
-                         "async_method_call (ec = "
-                      << ec << ")\n";
-            return;
-        }
-        std::cout << "TestYieldFunction return " << testValue << "\n";
-    },
+            if (ec)
+            {
+                std::cerr << "TestYieldFunction returned error with "
+                             "async_method_call (ec = "
+                          << ec << ")\n";
+                return;
+            }
+            std::cout << "TestYieldFunction return " << testValue << "\n";
+        },
         "xyz.openbmc_project.asio-test", "/xyz/openbmc_project/test",
         "xyz.openbmc_project.test", "TestYieldFunction", int32_t(41));
     io.run();