From Jason Turner

[range.prim.data]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpw2r8sbbe/{from.md → to.md} +28 -0
tmp/tmpw2r8sbbe/{from.md → to.md} RENAMED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ### `ranges::data` <a id="range.prim.data">[[range.prim.data]]</a>
2
+
3
+ The name `ranges::data` denotes a customization point object
4
+ [[customization.point.object]].
5
+
6
+ Given a subexpression `E` with type `T`, let `t` be an lvalue that
7
+ denotes the reified object for `E`. Then:
8
+
9
+ - If `E` is an rvalue and `enable_borrowed_range<remove_cv_t<T>>` is
10
+ `false`, `ranges::data(E)` is ill-formed.
11
+ - Otherwise, if `T` is an array type [[basic.compound]] and
12
+ `remove_all_extents_t<T>` is an incomplete type, `ranges::data(E)` is
13
+ ill-formed with no diagnostic required.
14
+ - Otherwise, if `decay-copy(t.data())` is a valid expression of pointer
15
+ to object type, `ranges::data(E)` is expression-equivalent to
16
+ `decay-copy(t.data())`.
17
+ - Otherwise, if `ranges::begin(t)` is a valid expression whose type
18
+ models `contiguous_iterator`, `ranges::data(E)` is
19
+ expression-equivalent to `to_address(ranges::begin(E))`.
20
+ - Otherwise, `ranges::data(E)` is ill-formed.
21
+
22
+ [*Note 1*: Diagnosable ill-formed cases above result in substitution
23
+ failure when `ranges::data(E)` appears in the immediate context of a
24
+ template instantiation. — *end note*]
25
+
26
+ [*Note 2*: Whenever `ranges::data(E)` is a valid expression, it has
27
+ pointer to object type. — *end note*]
28
+