Skip to content

Commit

Permalink
Restyled by clang-format
Browse files Browse the repository at this point in the history
  • Loading branch information
restyled-commits committed Feb 16, 2022
1 parent e893217 commit 4d166e9
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions src/platform/ESP32/ESP32Config.h
Original file line number Diff line number Diff line change
Expand Up @@ -114,18 +114,15 @@ struct ESP32Config::Key

bool operator==(const Key & other) const;

template<typename T, typename std::enable_if_t<std::is_convertible<T, const char *>::value, int> = 0>
Key(const char * aNamespace, T aName) :
Namespace(aNamespace), Name(aName)
template <typename T, typename std::enable_if_t<std::is_convertible<T, const char *>::value, int> = 0>
Key(const char * aNamespace, T aName) : Namespace(aNamespace), Name(aName)
{}

template<size_t N>
Key(const char * aNamespace, const char (& aName)[N]) :
Namespace(aNamespace), Name(aName)
template <size_t N>
Key(const char * aNamespace, const char (&aName)[N]) : Namespace(aNamespace), Name(aName)
{
// Note: N includes null-terminator.
static_assert(N <= ESP32Config::kMaxConfigKeyNameLength + 1,
"Key too long");
static_assert(N <= ESP32Config::kMaxConfigKeyNameLength + 1, "Key too long");
}
};

Expand Down

0 comments on commit 4d166e9

Please sign in to comment.