|
3764 | 3764 | An operand with volatile-qualified type is deprecated;
|
3765 | 3765 | see~\ref{depr.volatile.type}.
|
3766 | 3766 | The value of the operand object is modified\iref{defns.access}
|
3767 |
| -by adding \tcode{1} to it. |
| 3767 | +as if it were the operand of the prefix \tcode{++} operator\iref{expr.pre.incr}. |
3768 | 3768 | The
|
3769 | 3769 | \indextext{value computation}%
|
3770 | 3770 | value computation of the \tcode{++} expression is sequenced before the
|
|
3779 | 3779 | \end{note}
|
3780 | 3780 | The result is a prvalue. The type of the result is the cv-unqualified
|
3781 | 3781 | version of the type of the operand.
|
3782 |
| -If the operand is a bit-field that cannot represent the incremented value, the |
3783 |
| -resulting value of the bit-field is |
3784 |
| -\impldefplain{value of bit-field that cannot represent!incremented value}. |
3785 |
| -See also~\ref{expr.add} |
3786 |
| -and~\ref{expr.ass}. |
3787 | 3782 |
|
3788 | 3783 | \pnum
|
3789 | 3784 | \indextext{expression!decrement}%
|
|
4785 | 4780 | \pnum
|
4786 | 4781 | \indextext{expression!increment}%
|
4787 | 4782 | \indextext{expression!decrement}%
|
4788 |
| -The operand of prefix \tcode{++} |
4789 | 4783 | \indextext{operator!increment}%
|
| 4784 | +\indextext{operator!decrement}% |
4790 | 4785 | \indextext{prefix \tcode{++}}%
|
4791 |
| -is modified\iref{defns.access} by adding \tcode{1}. |
4792 | 4786 | \indextext{prefix \tcode{--}}%
|
4793 |
| -The operand shall be a modifiable lvalue. The type of the operand shall |
4794 |
| -be an arithmetic type other than \cv{}~\tcode{bool}, |
4795 |
| -or a pointer to a completely-defined object type. |
| 4787 | +The operand of prefix \tcode{++} or \tcode{--} |
| 4788 | +shall not be of type \cv{}~\tcode{bool}. |
4796 | 4789 | An operand with volatile-qualified type is deprecated;
|
4797 | 4790 | see~\ref{depr.volatile.type}.
|
4798 |
| -The result is the updated operand; it is an lvalue, and it is a |
4799 |
| -bit-field if the operand is a bit-field. |
4800 |
| -The expression \tcode{++x} is equivalent to \tcode{x+=1}. |
4801 |
| -\indextext{operator!\idxcode{+=}}% |
4802 |
| -\begin{note} |
4803 |
| -See the discussions of addition\iref{expr.add} and assignment |
4804 |
| -operators\iref{expr.ass} for information on conversions. |
4805 |
| -\end{note} |
4806 |
| - |
4807 |
| -\pnum |
4808 |
| -The operand of prefix |
4809 |
| -\indextext{operator!decrement}% |
4810 |
| -\tcode{--} is modified\iref{defns.access} by subtracting \tcode{1}. |
4811 |
| -The requirements on the operand of prefix |
4812 |
| -\tcode{--} and the properties of its result are otherwise the same as |
4813 |
| -those of prefix \tcode{++}. |
| 4791 | +The expression \tcode{++x} is otherwise equivalent to \tcode{x+=1} and |
| 4792 | +the expression \tcode{--x} is otherwise equivalent to \tcode{x-=1}\iref{expr.ass}. |
4814 | 4793 | \begin{note}
|
4815 | 4794 | For postfix increment and decrement, see~\ref{expr.post.incr}.
|
4816 | 4795 | \end{note}
|
|
0 commit comments