diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2019-01-18 15:04:15 +0200 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2019-01-19 00:52:15 +0200 |
commit | 576c9454cfc9529852a7b0da3e5bfb465fb4baa5 (patch) | |
tree | d28615c4593bceb286c4c3478d93bf40f14c3d1c | |
parent | 479264dfcaca61f08a0609db584d11d8fb252103 (diff) |
libcamera: utils: Don't use C++17 nested namespaces
Nesting namespace names in a single namespace declaration is a C++17
feature. As libcamera depends on C++11 only, nest two separate namespace
declarations instead.
Reported-by: Shik Chen <shik@google.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
-rw-r--r-- | src/libcamera/include/utils.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/libcamera/include/utils.h b/src/libcamera/include/utils.h index a2e450b3..73fa2e69 100644 --- a/src/libcamera/include/utils.h +++ b/src/libcamera/include/utils.h @@ -11,7 +11,9 @@ #define ARRAY_SIZE(a) (sizeof(a) / sizeof(a[0])) -namespace libcamera::utils { +namespace libcamera { + +namespace utils { /* C++11 doesn't provide std::make_unique */ template<typename T, typename... Args> @@ -20,6 +22,8 @@ std::unique_ptr<T> make_unique(Args&&... args) return std::unique_ptr<T>(new T(std::forward<Args>(args)...)); } -} /* namespace libcamera::utils */ +} /* namespace utils */ + +} /* namespace libcamera */ #endif /* __LIBCAMERA_UTILS_H__ */ |