Replace type aliases deprecated/removed in C++17/C++20 from FixedArray

- Raised as issue #551
- Also adds C++20 to the set of ALLOWED_CXX_STANDARDS, although this
  will require a version of CMake >= 3.12.

Change-Id: I0f13c72e93a35391fd2d18590b4243a329a2322c
This commit is contained in:
Alex Stewart
2020-05-24 19:18:38 +01:00
parent adb973e4a3
commit 99efa54bdb
2 changed files with 8 additions and 8 deletions
+1 -1
View File
@@ -44,7 +44,7 @@ set(CMAKE_CXX_STANDARD ${DEFAULT_CXX_STANDARD} CACHE STRING
"C++ standard (minimum 11)" FORCE)
# Restrict CMAKE_CXX_STANDARD to the valid versions permitted and ensure that
# if one was forced via -D that it is in the valid set.
set(ALLOWED_CXX_STANDARDS 11 14 17)
set(ALLOWED_CXX_STANDARDS 11 14 17 20)
set_property(CACHE CMAKE_CXX_STANDARD PROPERTY STRINGS ${ALLOWED_CXX_STANDARDS})
list(FIND ALLOWED_CXX_STANDARDS ${CMAKE_CXX_STANDARD} POSITION)
if (POSITION LESS 0)
+7 -7
View File
@@ -105,13 +105,13 @@ class FixedArray {
public:
using allocator_type = typename AllocatorTraits::allocator_type;
using value_type = typename allocator_type::value_type;
using pointer = typename allocator_type::pointer;
using const_pointer = typename allocator_type::const_pointer;
using reference = typename allocator_type::reference;
using const_reference = typename allocator_type::const_reference;
using size_type = typename allocator_type::size_type;
using difference_type = typename allocator_type::difference_type;
using value_type = typename AllocatorTraits::value_type;
using pointer = typename AllocatorTraits::pointer;
using const_pointer = typename AllocatorTraits::const_pointer;
using reference = value_type&;
using const_reference = const value_type&;
using size_type = typename AllocatorTraits::size_type;
using difference_type = typename AllocatorTraits::difference_type;
using iterator = pointer;
using const_iterator = const_pointer;
using reverse_iterator = std::reverse_iterator<iterator>;