Init
This commit is contained in:
68
cppdraft/array/members.md
Normal file
68
cppdraft/array/members.md
Normal file
@@ -0,0 +1,68 @@
|
||||
[array.members]
|
||||
|
||||
# 23 Containers library [[containers]](./#containers)
|
||||
|
||||
## 23.3 Sequence containers [[sequences]](sequences#array.members)
|
||||
|
||||
### 23.3.3 Class template array [[array]](array#members)
|
||||
|
||||
#### 23.3.3.3 Member functions [array.members]
|
||||
|
||||
[ð](#lib:array,size)
|
||||
|
||||
`constexpr size_type size() const noexcept;
|
||||
`
|
||||
|
||||
[1](#1)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L6247)
|
||||
|
||||
*Returns*: N[.](#1.sentence-1)
|
||||
|
||||
[ð](#lib:array,data)
|
||||
|
||||
`constexpr T* data() noexcept;
|
||||
constexpr const T* data() const noexcept;
|
||||
`
|
||||
|
||||
[2](#2)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L6259)
|
||||
|
||||
*Returns*: A pointer such that [data(), data() + size()) is a valid range[.](#2.sentence-1)
|
||||
|
||||
For a
|
||||
non-empty array, data() == addressof(front()) is true[.](#2.sentence-2)
|
||||
|
||||
[ð](#lib:array,fill)
|
||||
|
||||
`constexpr void fill(const T& u);
|
||||
`
|
||||
|
||||
[3](#3)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L6271)
|
||||
|
||||
*Effects*: As if by fill_n(begin(), N, u)[.](#3.sentence-1)
|
||||
|
||||
[ð](#lib:array,swap)
|
||||
|
||||
`constexpr void swap(array& y) noexcept(is_nothrow_swappable_v<T>);
|
||||
`
|
||||
|
||||
[4](#4)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L6282)
|
||||
|
||||
*Effects*: Equivalent to swap_ranges(begin(), end(), y.begin())[.](#4.sentence-1)
|
||||
|
||||
[5](#5)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L6286)
|
||||
|
||||
[*Note [1](#note-1)*:
|
||||
|
||||
Unlike the swap function for other containers, array::swap takes linear time, can exit via an exception, and does not cause iterators to
|
||||
become associated with the other container[.](#5.sentence-1)
|
||||
|
||||
â *end note*]
|
||||
Reference in New Issue
Block a user