blob: 0b72a09166778d4791b75520900e308206cc8698 [file] [log] [blame]
Brian Silverman4a2409e2018-08-04 23:24:02 -07001[/
2 Copyright 2007 John Maddock.
3 Distributed under the Boost Software License, Version 1.0.
4 (See accompanying file LICENSE_1_0.txt or copy at
5 http://www.boost.org/LICENSE_1_0.txt).
6]
7
8[section:remove_all_extents remove_all_extents]
9
10 template <class T>
11 struct remove_all_extents
12 {
13 typedef __below type;
14 };
15
16 template <class T> using remove_all_extents_t = typename remove_all_extents<T>::type; // C++11 and above
17
18__type If `T` is an array type, then removes all of the array bounds on `T`, otherwise
19leaves `T` unchanged.
20
21__std_ref 8.3.4.
22
23[all_compilers]
24
25__header ` #include <boost/type_traits/remove_all_extents.hpp>` or ` #include <boost/type_traits.hpp>`
26
27[table Examples
28
29[ [Expression] [Result Type]]
30
31[[`remove_all_extents<int>::type`][`int`]]
32
33[[`remove_all_extents<int const[2]>::type`] [`int const`]]
34
35[[`remove_all_extents<int[][2]>::type`] [`int`]]
36
37[[`remove_all_extents<int[2][3][4]>::type`] [`int`]]
38
39[[`remove_all_extents<int const*>::type`] [`int const*`]]
40
41]
42
43[endsect]
44