From Jason Turner

[expr.sub]

Diff to HTML by rtfpessoa

tmp/tmpuje7v3wq/{from.md → to.md} RENAMED
@@ -2,23 +2,24 @@
2
 
3
  A *subscript expression* is a postfix expression followed by square
4
  brackets containing a possibly empty, comma-separated list of
5
  *initializer-clause*s that constitute the arguments to the subscript
6
  operator. The *postfix-expression* and the initialization of the object
7
- parameter of any applicable subscript operator function is sequenced
8
- before each expression in the *expression-list* and also before any
9
- default argument. The initialization of a non-object parameter of a
10
- subscript operator function `S` [[over.sub]], including every associated
11
- value computation and side effect, is indeterminately sequenced with
12
- respect to that of any other non-object parameter of `S`.
 
13
 
14
  With the built-in subscript operator, an *expression-list* shall be
15
  present, consisting of a single *assignment-expression*. One of the
16
  expressions shall be a glvalue of type “array of `T`” or a prvalue of
17
  type “pointer to `T`” and the other shall be a prvalue of unscoped
18
  enumeration or integral type. The result is of type “`T`”. The type
19
- “`T`” shall be a completely-defined object type.[^11]
20
 
21
  The expression `E1[E2]` is identical (by definition) to `*((E1)+(E2))`,
22
  except that in the case of an array operand, the result is an lvalue if
23
  that operand is an lvalue and an xvalue otherwise.
24
 
 
2
 
3
  A *subscript expression* is a postfix expression followed by square
4
  brackets containing a possibly empty, comma-separated list of
5
  *initializer-clause*s that constitute the arguments to the subscript
6
  operator. The *postfix-expression* and the initialization of the object
7
+ parameter [[dcl.fct]] of any applicable subscript operator function
8
+ [[over.sub]] is sequenced before each expression in the
9
+ *expression-list* and also before any default argument
10
+ [[dcl.fct.default]]. The initialization of a non-object parameter of a
11
+ subscript operator function `S`, including every associated value
12
+ computation and side effect, is indeterminately sequenced with respect
13
+ to that of any other non-object parameter of `S`.
14
 
15
  With the built-in subscript operator, an *expression-list* shall be
16
  present, consisting of a single *assignment-expression*. One of the
17
  expressions shall be a glvalue of type “array of `T`” or a prvalue of
18
  type “pointer to `T`” and the other shall be a prvalue of unscoped
19
  enumeration or integral type. The result is of type “`T`”. The type
20
+ “`T`” shall be a completely-defined object type.[^10]
21
 
22
  The expression `E1[E2]` is identical (by definition) to `*((E1)+(E2))`,
23
  except that in the case of an array operand, the result is an lvalue if
24
  that operand is an lvalue and an xvalue otherwise.
25