summaryrefslogtreecommitdiff
path: root/Documentation/coding-style.rst
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-08-22 17:19:31 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-08-25 02:03:09 +0300
commitb869d4463ef38934da35ffaf287870541e0dee47 (patch)
treedbf2f31612ca28eb82a8cabe0c846886d6f23d14 /Documentation/coding-style.rst
parentf976eb5cb63f0c5e802dbd4faefa82eb927c2f47 (diff)
meson: Switch to C++17
Due to popular request, move from C++14 to C++17. This will allow dropping some custom constructs (such as a custom utils::clamp), benefiting from new language features, and dropping gcc 5 and 6 from the compilation tests. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Diffstat (limited to 'Documentation/coding-style.rst')
-rw-r--r--Documentation/coding-style.rst5
1 files changed, 2 insertions, 3 deletions
diff --git a/Documentation/coding-style.rst b/Documentation/coding-style.rst
index 7acba37b..7c56a1b7 100644
--- a/Documentation/coding-style.rst
+++ b/Documentation/coding-style.rst
@@ -88,13 +88,12 @@ headers, and with double quotes for other libcamera headers.
C++ Specific Rules
------------------
-The code shall be implemented in C++14, with the following caveats:
+The code shall be implemented in C++17, with the following caveats:
* Type inference (auto and decltype) shall be used with caution, to avoid
drifting towards an untyped language.
* The explicit, override and final specifiers are to be used where applicable.
-* General-purpose smart pointers (std::unique_ptr) deprecate std::auto_ptr.
- Smart pointers, as well as shared pointers and weak pointers, shall not be
+* Smart pointers, as well as shared pointers and weak pointers, shall not be
overused.
* Classes are encouraged to define move constructors and assignment operators
where applicable, and generally make use of the features offered by rvalue