From 3d6d3182ee0b0e88b81fbbbe5c91dea3e99425a9 Mon Sep 17 00:00:00 2001 From: Patrick Venture Date: Fri, 31 Aug 2018 09:33:09 -0700 Subject: update .clang-format Added the header inclusion order to the .clang-format file generated these changes. Change-Id: I4f51a20f469de431ee6a5ba78e3f4da39c980fab Signed-off-by: Patrick Venture --- .clang-format | 22 ++++++++++++++---- mslverify/util.hpp | 6 ++--- mslverify/verify.cpp | 9 +++++--- src/callback.hpp | 9 +++++--- src/count.hpp | 3 ++- src/data_types.hpp | 12 ++++++---- src/elog.hpp | 20 ++++++++++------ src/event.hpp | 5 ++-- src/event_manager.cpp | 4 +++- src/event_serialize.cpp | 9 ++++---- src/event_serialize.hpp | 6 +++-- src/format.hpp | 48 ++++++++++++++++++++++++++------------- src/journal.hpp | 9 +++++--- src/main.cpp | 1 + src/method.hpp | 6 +++-- src/pathwatch.hpp | 3 ++- src/pathwatchimpl.hpp | 10 ++++---- src/propertywatch.hpp | 3 ++- src/propertywatchimpl.hpp | 7 +++--- src/resolve_errors.cpp | 4 +++- src/sdbusplus.hpp | 5 ++-- src/sdevent/event.hpp | 3 ++- src/sdevent/source.hpp | 3 ++- src/sdevent/timer.hpp | 9 ++++---- src/snmp_trap.cpp | 9 ++++---- src/snmp_trap.hpp | 3 ++- src/test/callbackgentest.cpp | 4 +++- src/test/callbackgroupgentest.cpp | 4 +++- src/test/callbacktest.cpp | 4 ++-- src/test/conditiongentest.cpp | 4 +++- src/test/interfaceaddtest.cpp | 6 +++-- src/test/pathgentest.cpp | 4 +++- src/test/propertygentest.cpp | 4 +++- src/test/propertywatchgentest.cpp | 4 +++- src/test/propertywatchtest.cpp | 27 ++++++++++++++-------- src/test/propertywatchtest.hpp | 39 +++++++++++++++++++------------ src/tupleref.hpp | 3 ++- 37 files changed, 219 insertions(+), 112 deletions(-) diff --git a/.clang-format b/.clang-format index bbc1bb1..ea71ad6 100644 --- a/.clang-format +++ b/.clang-format @@ -17,7 +17,7 @@ AllowShortLoopsOnASingleLine: false AlwaysBreakAfterDefinitionReturnType: None AlwaysBreakAfterReturnType: None AlwaysBreakBeforeMultilineStrings: false -AlwaysBreakTemplateDeclarations: false +AlwaysBreakTemplateDeclarations: true BinPackArguments: true BinPackParameters: true BraceWrapping: @@ -42,12 +42,26 @@ ConstructorInitializerAllOnOneLineOrOnePerLine: false ConstructorInitializerIndentWidth: 4 ContinuationIndentWidth: 4 Cpp11BracedListStyle: true -DerivePointerAlignment: true +DerivePointerAlignment: false PointerAlignment: Left DisableFormat: false ExperimentalAutoDetectBinPacking: false FixNamespaceComments: true ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ] +IncludeBlocks: Regroup +IncludeCategories: + - Regex: '^[<"](gtest|gmock)' + Priority: 5 + - Regex: '^"config.h"' + Priority: -1 + - Regex: '^".*\.hpp"' + Priority: 1 + - Regex: '^<.*\.h>' + Priority: 2 + - Regex: '^<.*' + Priority: 3 + - Regex: '.*' + Priority: 4 IndentCaseLabels: true IndentWidth: 4 IndentWrappedFunctionNames: true @@ -65,9 +79,9 @@ PenaltyBreakFirstLessLess: 120 PenaltyBreakString: 1000 PenaltyExcessCharacter: 1000000 PenaltyReturnTypeOnItsOwnLine: 60 -PointerAlignment: Right ReflowComments: true -SortIncludes: false +SortIncludes: true +SortUsingDeclarations: true SpaceAfterCStyleCast: false SpaceBeforeAssignmentOperators: true SpaceBeforeParens: ControlStatements diff --git a/mslverify/util.hpp b/mslverify/util.hpp index f487cee..e0d07ca 100644 --- a/mslverify/util.hpp +++ b/mslverify/util.hpp @@ -1,10 +1,10 @@ #pragma once +#include +#include +#include #include #include -#include -#include -#include #include namespace util diff --git a/mslverify/verify.cpp b/mslverify/verify.cpp index c9c06aa..a4b3ece 100644 --- a/mslverify/verify.cpp +++ b/mslverify/verify.cpp @@ -14,14 +14,16 @@ * limitations under the License. */ +#include "util.hpp" + #include #include #include -#include "util.hpp" using namespace std::literals::string_literals; -template struct BusMeetsMSL +template +struct BusMeetsMSL { std::string path; @@ -43,7 +45,8 @@ template struct BusMeetsMSL } }; -template struct PathMeetsMSL +template +struct PathMeetsMSL { auto operator()(const T& arg) { diff --git a/src/callback.hpp b/src/callback.hpp index e1e2325..c79dcd0 100644 --- a/src/callback.hpp +++ b/src/callback.hpp @@ -1,8 +1,9 @@ #pragma once -#include #include "data_types.hpp" +#include + namespace phosphor { namespace dbus @@ -124,7 +125,8 @@ class IndexedCallback : public Callback * * @tparam CallbackAccess - Access to the array of callbacks. */ -template class GroupOfCallbacks : public Callback +template +class GroupOfCallbacks : public Callback { public: GroupOfCallbacks() = delete; @@ -155,7 +157,8 @@ template class GroupOfCallbacks : public Callback /** @class ConditionalCallback * @brief Callback adaptor that asssociates a condition with a callback. */ -template class ConditionalCallback : public Callback +template +class ConditionalCallback : public Callback { public: ConditionalCallback() = delete; diff --git a/src/count.hpp b/src/count.hpp index af3998a..3e18e20 100644 --- a/src/count.hpp +++ b/src/count.hpp @@ -31,7 +31,8 @@ namespace monitoring * If the oneshot parameter is true, then this condition won't pass * again until it fails at least once. */ -template class CountCondition : public IndexedConditional +template +class CountCondition : public IndexedConditional { public: CountCondition() = delete; diff --git a/src/data_types.hpp b/src/data_types.hpp index cf0d69e..c96f1a0 100644 --- a/src/data_types.hpp +++ b/src/data_types.hpp @@ -1,8 +1,9 @@ #pragma once +#include "tupleref.hpp" + #include #include -#include "tupleref.hpp" namespace any_ns = std::experimental; @@ -46,7 +47,8 @@ template using TupleRefMap = std::map, Value, TupleOfRefsLess>; /** @brief A vector of references. */ -template using RefVector = std::vector>; +template +using RefVector = std::vector>; /** @brief * @@ -92,11 +94,13 @@ using PropertyIndex = * 1. Remove references. * 2. Remove 'const' and 'volatile'. */ -template struct Downcast +template +struct Downcast { using Type = std::remove_cv_t>; }; -template using DowncastType = typename Downcast::Type; +template +using DowncastType = typename Downcast::Type; } // namespace monitoring } // namespace dbus diff --git a/src/elog.hpp b/src/elog.hpp index 24e2009..d98984c 100644 --- a/src/elog.hpp +++ b/src/elog.hpp @@ -1,9 +1,10 @@ #pragma once +#include "callback.hpp" + +#include #include #include -#include "callback.hpp" #include -#include namespace phosphor { @@ -15,7 +16,8 @@ namespace monitoring /** @struct ToString * @brief Convert numbers to strings */ -template struct ToString +template +struct ToString { static auto op(T&& value) { @@ -23,7 +25,8 @@ template struct ToString } }; -template <> struct ToString +template <> +struct ToString { static auto op(const std::string& value) { @@ -66,7 +69,8 @@ namespace detail * @tparam T - Error log type * @tparam Args - Metadata fields types. */ -template struct CallElog +template +struct CallElog { static void op(Args&&... args) { @@ -84,7 +88,8 @@ template struct CallElog * @tparam Args - Metadata fields types. * @param[in] arguments - Metadata fields to be added to the error log */ -template class Elog : public ElogBase +template +class Elog : public ElogBase { public: Elog(const Elog&) = delete; @@ -210,7 +215,8 @@ class ElogWithMetadataCapture : public IndexedCallback * @tparam Args - Metadata fields types. * @param[in] arguments - Metadata fields to be added to the error log */ -template auto makeElog(Args&&... arguments) +template +auto makeElog(Args&&... arguments) { return std::make_unique>(std::forward(arguments)...); } diff --git a/src/event.hpp b/src/event.hpp index a2a2236..f9104f8 100644 --- a/src/event.hpp +++ b/src/event.hpp @@ -1,9 +1,9 @@ #pragma once -#include #include "callback.hpp" #include "event_manager.hpp" +#include #include namespace phosphor @@ -76,7 +76,8 @@ class EventBase : public IndexedCallback * * @tparam T - The C++ type of the property values being traced. */ -template class Event : public EventBase +template +class Event : public EventBase { public: Event() = delete; diff --git a/src/event_manager.cpp b/src/event_manager.cpp index 57a8478..874c5a8 100644 --- a/src/event_manager.cpp +++ b/src/event_manager.cpp @@ -15,8 +15,10 @@ */ #include "config.h" -#include "event.hpp" + #include "event_manager.hpp" + +#include "event.hpp" #include "event_serialize.hpp" #include diff --git a/src/event_serialize.cpp b/src/event_serialize.cpp index ddfc4b6..ca43c41 100644 --- a/src/event_serialize.cpp +++ b/src/event_serialize.cpp @@ -1,11 +1,12 @@ +#include "config.h" + +#include "event_serialize.hpp" + +#include #include #include -#include #include - -#include "event_serialize.hpp" #include -#include "config.h" // Register class version // From cereal documentation; diff --git a/src/event_serialize.hpp b/src/event_serialize.hpp index f052845..d331950 100644 --- a/src/event_serialize.hpp +++ b/src/event_serialize.hpp @@ -1,9 +1,11 @@ #pragma once -#include -#include "event_entry.hpp" #include "config.h" +#include "event_entry.hpp" + +#include + namespace phosphor { namespace events diff --git a/src/format.hpp b/src/format.hpp index f622f2e..32a85f8 100644 --- a/src/format.hpp +++ b/src/format.hpp @@ -12,62 +12,77 @@ namespace detail { /** @brief Map format strings to undecorated C++ types. */ -template struct GetFormatType +template +struct GetFormatType { }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "%d"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%hhd"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%hd"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%d"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%ld"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%lld"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%hhd"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%hd"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%d"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%ld"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%lld"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%s"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%s"; }; -template <> struct GetFormatType +template <> +struct GetFormatType { static constexpr auto format = "=%s"; }; @@ -75,7 +90,8 @@ template <> struct GetFormatType } // namespace detail /** @brief Get the format string for a C++ type. */ -template struct GetFormat +template +struct GetFormat { static constexpr auto format = detail::GetFormatType>::format; diff --git a/src/journal.hpp b/src/journal.hpp index 249a7a2..e69a709 100644 --- a/src/journal.hpp +++ b/src/journal.hpp @@ -1,9 +1,10 @@ #pragma once -#include #include "callback.hpp" #include "format.hpp" +#include + namespace phosphor { namespace dbus @@ -50,7 +51,8 @@ class JournalBase : public IndexedCallback */ namespace detail { -template struct Display +template +struct Display { static auto op(T&& value) { @@ -58,7 +60,8 @@ template struct Display } }; -template <> struct Display +template <> +struct Display { static auto op(const std::string& value) { diff --git a/src/main.cpp b/src/main.cpp index 3b75e3b..0626081 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -15,6 +15,7 @@ */ #include "config.h" + #include "generated.hpp" #include "sdbusplus.hpp" diff --git a/src/method.hpp b/src/method.hpp index 7c29205..86326b6 100644 --- a/src/method.hpp +++ b/src/method.hpp @@ -1,8 +1,9 @@ #pragma once -#include #include "callback.hpp" +#include + namespace phosphor { namespace dbus @@ -19,7 +20,8 @@ namespace detail * @tparam DBusInterface - The DBus interface to use. * @tparam MethodArgs - DBus method argument types. */ -template struct CallDBusMethod +template +struct CallDBusMethod { static void op(const std::string& bus, const std::string& path, const std::string& iface, const std::string& method, diff --git a/src/pathwatch.hpp b/src/pathwatch.hpp index db81bec..b0b8b42 100644 --- a/src/pathwatch.hpp +++ b/src/pathwatch.hpp @@ -22,7 +22,8 @@ class Callback; /** @class PathWatch * @brief Watch on object path for interfaceadded/interfaceremoved signals */ -template class PathWatch : public Watch +template +class PathWatch : public Watch { public: PathWatch() = delete; diff --git a/src/pathwatchimpl.hpp b/src/pathwatchimpl.hpp index 6be0f50..8b7e8ee 100644 --- a/src/pathwatchimpl.hpp +++ b/src/pathwatchimpl.hpp @@ -5,13 +5,14 @@ */ #pragma once -#include -#include -#include #include "callback.hpp" #include "data_types.hpp" #include "pathwatch.hpp" +#include +#include +#include + namespace phosphor { namespace dbus @@ -19,7 +20,8 @@ namespace dbus namespace monitoring { -template void PathWatch::start() +template +void PathWatch::start() { if (alreadyRan) { diff --git a/src/propertywatch.hpp b/src/propertywatch.hpp index 2cbf6f5..a94b99e 100644 --- a/src/propertywatch.hpp +++ b/src/propertywatch.hpp @@ -25,7 +25,8 @@ class Callback; * A property watch maintains the state of one or more DBus properties * as specified by the supplied index. */ -template class PropertyWatch : public Watch +template +class PropertyWatch : public Watch { public: PropertyWatch() = delete; diff --git a/src/propertywatchimpl.hpp b/src/propertywatchimpl.hpp index 6500a15..2a44abc 100644 --- a/src/propertywatchimpl.hpp +++ b/src/propertywatchimpl.hpp @@ -1,12 +1,13 @@ #pragma once -#include -#include -#include #include "callback.hpp" #include "data_types.hpp" #include "propertywatch.hpp" +#include +#include +#include + namespace phosphor { namespace dbus diff --git a/src/resolve_errors.cpp b/src/resolve_errors.cpp index 47277eb..e932aff 100644 --- a/src/resolve_errors.cpp +++ b/src/resolve_errors.cpp @@ -13,10 +13,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -#include #include "resolve_errors.hpp" + #include "sdbusplus.hpp" +#include + namespace phosphor { namespace dbus diff --git a/src/sdbusplus.hpp b/src/sdbusplus.hpp index 0a8e715..96a8903 100644 --- a/src/sdbusplus.hpp +++ b/src/sdbusplus.hpp @@ -1,11 +1,12 @@ #pragma once +#include "data_types.hpp" + #include #include +#include #include #include -#include -#include "data_types.hpp" struct Loop; diff --git a/src/sdevent/event.hpp b/src/sdevent/event.hpp index e3d1b22..9ef5791 100644 --- a/src/sdevent/event.hpp +++ b/src/sdevent/event.hpp @@ -1,9 +1,10 @@ #pragma once +#include + #include #include #include -#include // TODO: openbmc/openbmc#1720 - add error handling for sd_event API failures diff --git a/src/sdevent/source.hpp b/src/sdevent/source.hpp index 4f837be..6b20c29 100644 --- a/src/sdevent/source.hpp +++ b/src/sdevent/source.hpp @@ -1,8 +1,9 @@ #pragma once +#include + #include #include -#include // TODO: openbmc/openbmc#1720 - add error handling for sd_event API failures diff --git a/src/sdevent/timer.hpp b/src/sdevent/timer.hpp index 5e45b94..405da4e 100644 --- a/src/sdevent/timer.hpp +++ b/src/sdevent/timer.hpp @@ -1,12 +1,13 @@ #pragma once +#include "sdevent/event.hpp" +#include "sdevent/source.hpp" + +#include + #include #include #include -#include - -#include "sdevent/source.hpp" -#include "sdevent/event.hpp" // TODO: openbmc/openbmc#1720 - add error handling for sd_event API failures diff --git a/src/snmp_trap.cpp b/src/snmp_trap.cpp index 27b8133..cc730b7 100644 --- a/src/snmp_trap.cpp +++ b/src/snmp_trap.cpp @@ -1,11 +1,12 @@ #include "snmp_trap.hpp" + +#include +#include +#include #include #include -#include -#include -#include -#include #include +#include namespace phosphor { namespace dbus diff --git a/src/snmp_trap.hpp b/src/snmp_trap.hpp index 2f93189..4555e65 100644 --- a/src/snmp_trap.hpp +++ b/src/snmp_trap.hpp @@ -47,7 +47,8 @@ class ErrorTrap : public Trap /** @class SNMPTrap * @brief SNMP trap callback implementation. */ -template class SNMPTrap : public Callback +template +class SNMPTrap : public Callback { public: SNMPTrap(const SNMPTrap&) = delete; diff --git a/src/test/callbackgentest.cpp b/src/test/callbackgentest.cpp index cda665d..87bf160 100644 --- a/src/test/callbackgentest.cpp +++ b/src/test/callbackgentest.cpp @@ -1,7 +1,9 @@ +#include "data_types.hpp" + #include #include + #include -#include "data_types.hpp" using namespace phosphor::dbus::monitoring; diff --git a/src/test/callbackgroupgentest.cpp b/src/test/callbackgroupgentest.cpp index fe760ec..64811d7 100644 --- a/src/test/callbackgroupgentest.cpp +++ b/src/test/callbackgroupgentest.cpp @@ -1,7 +1,9 @@ +#include "data_types.hpp" + #include #include + #include -#include "data_types.hpp" using namespace phosphor::dbus::monitoring; diff --git a/src/test/callbacktest.cpp b/src/test/callbacktest.cpp index 78736f8..f0c96e0 100644 --- a/src/test/callbacktest.cpp +++ b/src/test/callbacktest.cpp @@ -1,7 +1,7 @@ -#include - #include "generated.hpp" +#include + using namespace phosphor::dbus::monitoring; TEST(JournalTest, Test) diff --git a/src/test/conditiongentest.cpp b/src/test/conditiongentest.cpp index d0df215..95d9907 100644 --- a/src/test/conditiongentest.cpp +++ b/src/test/conditiongentest.cpp @@ -1,7 +1,9 @@ +#include "data_types.hpp" + #include #include + #include -#include "data_types.hpp" using namespace phosphor::dbus::monitoring; diff --git a/src/test/interfaceaddtest.cpp b/src/test/interfaceaddtest.cpp index d80f437..aabacf0 100644 --- a/src/test/interfaceaddtest.cpp +++ b/src/test/interfaceaddtest.cpp @@ -1,8 +1,10 @@ +#include "event.hpp" +#include "pathwatchimpl.hpp" + #include #include + #include -#include "pathwatchimpl.hpp" -#include "event.hpp" using namespace std::string_literals; using namespace phosphor::dbus::monitoring; diff --git a/src/test/pathgentest.cpp b/src/test/pathgentest.cpp index 1f75153..9e0e073 100644 --- a/src/test/pathgentest.cpp +++ b/src/test/pathgentest.cpp @@ -1,7 +1,9 @@ +#include "data_types.hpp" + #include #include + #include -#include "data_types.hpp" using namespace std::string_literals; using namespace phosphor::dbus::monitoring; diff --git a/src/test/propertygentest.cpp b/src/test/propertygentest.cpp index e9da733..4124246 100644 --- a/src/test/propertygentest.cpp +++ b/src/test/propertygentest.cpp @@ -1,7 +1,9 @@ +#include "data_types.hpp" + #include #include + #include -#include "data_types.hpp" using namespace std::string_literals; using namespace phosphor::dbus::monitoring; diff --git a/src/test/propertywatchgentest.cpp b/src/test/propertywatchgentest.cpp index 2e446a4..b1fe6c4 100644 --- a/src/test/propertywatchgentest.cpp +++ b/src/test/propertywatchgentest.cpp @@ -1,7 +1,9 @@ +#include "data_types.hpp" + #include #include + #include -#include "data_types.hpp" using namespace std::string_literals; using namespace phosphor::dbus::monitoring; diff --git a/src/test/propertywatchtest.cpp b/src/test/propertywatchtest.cpp index bb021a2..1cf7729 100644 --- a/src/test/propertywatchtest.cpp +++ b/src/test/propertywatchtest.cpp @@ -1,7 +1,9 @@ -#include -#include "propertywatchimpl.hpp" #include "propertywatchtest.hpp" +#include "propertywatchimpl.hpp" + +#include + using namespace std::string_literals; using namespace phosphor::dbus::monitoring; @@ -47,10 +49,12 @@ const PropertyIndex watchIndex = { }, }; -template struct ExpectedValues +template +struct ExpectedValues { }; -template <> struct ExpectedValues +template <> +struct ExpectedValues { static auto& get(size_t i) { @@ -61,7 +65,8 @@ template <> struct ExpectedValues } }; -template <> struct ExpectedValues +template <> +struct ExpectedValues { static auto& get(size_t i) { @@ -72,7 +77,8 @@ template <> struct ExpectedValues } }; -template <> struct ExpectedValues +template <> +struct ExpectedValues { static auto& get(size_t i) { @@ -83,7 +89,8 @@ template <> struct ExpectedValues } }; -template <> struct ExpectedValues +template <> +struct ExpectedValues { static auto& get(size_t i) { @@ -94,7 +101,8 @@ template <> struct ExpectedValues } }; -template <> struct ExpectedValues +template <> +struct ExpectedValues { static auto& get(size_t i) { @@ -105,7 +113,8 @@ template <> struct ExpectedValues } }; -template void testStart() +template +void testStart() { using ::testing::_; using ::testing::Return; diff --git a/src/test/propertywatchtest.hpp b/src/test/propertywatchtest.hpp index d226f93..e27ba18 100644 --- a/src/test/propertywatchtest.hpp +++ b/src/test/propertywatchtest.hpp @@ -1,11 +1,12 @@ #pragma once -#include -#include -#include - #include "data_types.hpp" #include "sdbusplus/bus/match.hpp" +#include + +#include +#include + namespace phosphor { namespace dbus @@ -292,11 +293,13 @@ struct MockDBusInterface /** @class Expect * @brief Enable use of EXPECT_CALL from a C++ template. */ -template struct Expect +template +struct Expect { }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -309,7 +312,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -322,7 +326,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -335,7 +340,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -348,7 +354,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -361,7 +368,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -374,7 +382,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -387,7 +396,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, @@ -400,7 +410,8 @@ template <> struct Expect } }; -template <> struct Expect +template <> +struct Expect { template static auto& getProperties(MockObjType&& mockObj, const std::string& path, diff --git a/src/tupleref.hpp b/src/tupleref.hpp index 3e896be..18bd7f4 100644 --- a/src/tupleref.hpp +++ b/src/tupleref.hpp @@ -17,7 +17,8 @@ using TupleOfRefs = std::tuple...>; namespace detail { /** @brief Less than implementation for tuples of references. */ -template struct TupleOfRefsLess +template +struct TupleOfRefsLess { static constexpr bool compare(const T& l, const U& r) { -- cgit v1.2.1