This commit is contained in:
2025-10-25 03:02:53 +03:00
commit 043225d523
3416 changed files with 681196 additions and 0 deletions

33
cppdraft/array/cons.md Normal file
View File

@@ -0,0 +1,33 @@
[array.cons]
# 23 Containers library [[containers]](./#containers)
## 23.3 Sequence containers [[sequences]](sequences#array.cons)
### 23.3.3 Class template array [[array]](array#cons)
#### 23.3.3.2 Constructors, copy, and assignment [array.cons]
[1](#1)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L6218)
An array relies on the implicitly-declared special
member functions ([[class.default.ctor]](class.default.ctor "11.4.5.2Default constructors"), [[class.dtor]](class.dtor "11.4.7Destructors"), [[class.copy.ctor]](class.copy.ctor "11.4.5.3Copy/move constructors")) to
conform to the container requirements table in [[container.requirements]](container.requirements "23.2Requirements")[.](#1.sentence-1)
In addition to the requirements specified in the container requirements table,
the implicitly-declared move constructor and move assignment operator for array require that T be *Cpp17MoveConstructible* or *Cpp17MoveAssignable*,
respectively[.](#1.sentence-2)
[🔗](#itemdecl:1)
`template<class T, class... U>
array(T, U...) -> array<T, 1 + sizeof...(U)>;
`
[2](#2)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L6234)
*Mandates*: (is_same_v<T, U> && ...) is true[.](#2.sentence-1)