Difference between revisions of "cpp/named req/ContiguousContainer"
From cppreference.com
m (Added Spanish link) |
D41D8CD98F (Talk | contribs) (→Requirements: {{named req|ContiguousIterator}} => {{lconcept|contiguous_iterator}}) |
||
Line 10: | Line 10: | ||
* The type {{tt|X}} satisfies {{named req|Container}} | * The type {{tt|X}} satisfies {{named req|Container}} | ||
* The type {{tt|X}} supports {{named req|RandomAccessIterator}}s | * The type {{tt|X}} supports {{named req|RandomAccessIterator}}s | ||
− | * The member types {{c|X::iterator}} and {{c|X::const_iterator}} are {{named req|ContiguousIterator}}s | + | * The member types {{c|X::iterator}} and {{c|X::const_iterator}} are {{rev inl|until=c++20|{{named req|ContiguousIterator}}s}}{{rev inl|since=c++20|{{lconcept|contiguous_iterator}}s}} |
===Contiguous containers in the standard library=== | ===Contiguous containers in the standard library=== |
Revision as of 17:13, 19 May 2021
A ContiguousContainer is a Container that stores objects in contiguous memory locations.
Requirements
The type X
satisfies ContiguousContainer if
- The type
X
satisfies Container - The type
X
supports LegacyRandomAccessIterators - The member types X::iterator and X::const_iterator are LegacyContiguousIterators(until C++20)
contiguous_iterator
s(since C++20)
Contiguous containers in the standard library
stores and manipulates sequences of characters (class template) | |
(C++11) |
fixed-sized inplace contiguous array (class template) |
dynamic contiguous array (class template) |