File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 700700
701701\item Otherwise, the object indicated by the glvalue is read\iref {defns.access }.
702702Let \tcode {V} be the value contained in the object.
703- If \tcode {T} is an integer type,
704- the prvalue result is
705- the value of type \tcode {T} congruent\iref {basic.fundamental } to \tcode {V}, and
703+ The prvalue result is
704+ \begin {itemize }
705+ \item
706+ the value of type \tcode {T} congruent\iref {basic.fundamental } to \tcode {V}
707+ if \tcode {T} is an integer type,
708+ \item
709+ the result of \tcode {reinterpret_cast<T>(reinterpret_cast<std::uintptr_t>(V))}
710+ if \tcode {T} is volatile-qualified
711+ and \tcode {V} is a pointer value
712+ that is not valid in the context of the evaluation\iref {basic.compound }, and
713+ \item
706714\tcode {V} otherwise.
707715\end {itemize }
716+ \end {itemize }
708717
709718\pnum
710719\begin {note }
82488257let \tcode {V} be the result of the right operand;
82498258the object referred to by the left operand is
82508259modified\iref {defns.access } by replacing its value
8251- with \tcode {V} or,
8260+ with
8261+ \begin {itemize }
8262+ \item
8263+ the value congruent\iref {basic.fundamental } to \tcode {V}
82528264if the object is of integer type,
8253- with the value congruent\iref {basic.fundamental } to \tcode {V}.
8265+ \item
8266+ the result of \tcode {reinterpret_cast<T>(reinterpret_cast<std::uintptr_t>(V))}
8267+ if the left operand is a volatile-qualified glvalue of pointer type \tcode {T}
8268+ and \tcode {V} is a pointer value
8269+ that is not valid in the context of the evaluation\iref {basic.compound }, and
8270+ \item
8271+ \tcode {V} otherwise.
8272+ \end {itemize }
82548273
82558274\pnum
82568275\indextext {assignment!conversion by}%
Original file line number Diff line number Diff line change 41704170the specialization \tcode {atomic_ref<\placeholder {pointer-type}>} provides
41714171additional atomic operations appropriate to pointer types.
41724172
4173+ \pnum
4174+ Except during constant evaluation,
4175+ when an operation on an atomic pointer
4176+ would otherwise result in a pointer value \tcode {p}
4177+ that is not valid in the context of the evaluation\iref {basic.compound },
4178+ that result instead is
4179+ \tcode {reinterpret_cast<T*>(reinterpret_cast<uintptr_t>(p))}.
4180+
41734181\pnum
41744182The program is ill-formed
41754183if \tcode {is_always_lock_free} is \tcode {false} and
58185826Specializations of this partial specialization are standard-layout structs.
58195827They each have a trivial destructor.
58205828
5829+ \pnum
5830+ Except during constant evaluation,
5831+ when an operation on an atomic pointer
5832+ would otherwise result in a pointer value \tcode {p}
5833+ that is not valid in the context of the evaluation\iref {basic.compound },
5834+ that result instead is
5835+ \tcode {reinterpret_cast<T*>(reinterpret_cast<uintptr_t>(p))}.
5836+
58215837\pnum
58225838Descriptions are provided below only for members that differ from the primary template.
58235839
You can’t perform that action at this time.
0 commit comments