Move some variables to constexpr
clang-tidy flags these variables as having lifetime issues given that
they point to compile time parameters, resolve the error:
Tested: Code compiles, clang-tidy no longer returns an error on that
line.
Signed-off-by: Ed Tanous <ed.tanous@intel.com>
Change-Id: Iaa0da0c346786a79a6e66877082c3716bcffdf69
diff --git a/http/http_connection.h b/http/http_connection.h
index ef42f84..7cab789 100644
--- a/http/http_connection.h
+++ b/http/http_connection.h
@@ -113,7 +113,7 @@
template <typename C> static std::false_type f(...);
public:
- static const bool value = decltype(f<T>(nullptr))::value;
+ static constexpr bool value = decltype(f<T>(nullptr))::value;
};
template <typename T> struct IsAfterHandleArity3Impl
@@ -129,7 +129,7 @@
template <typename C> static std::false_type f(...);
public:
- static const bool value = decltype(f<T>(nullptr))::value;
+ static constexpr bool value = decltype(f<T>(nullptr))::value;
};
template <typename MW, typename Context, typename ParentContext>