Skip to content

[stmt.jump]/2 Fixed wording that does not apply to objects whose lifetime has ended #2872

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions source/statements.tex
Original file line number Diff line number Diff line change
Expand Up @@ -736,12 +736,12 @@
\pnum
\indextext{local variable!destruction of}%
\indextext{scope!destructor and exit from}%
On exit from a scope (however accomplished), objects with automatic storage
duration\iref{basic.stc.auto} that have been constructed in that scope are destroyed
in the reverse order of their construction. \begin{note} For temporaries,
see~\ref{class.temporary}. \end{note} Transfer out of a loop, out of a block, or back
past
an initialized variable with automatic storage duration involves the
On exit from a scope (however accomplished), variables that refer to objects with
automatic storage duration\iref{basic.stc.auto} declared in that scope will be destroyed
in the reverse order of their declaration. If a variable does not refer to an object
and the type of the variable has a non-trivial destructor, the behavior is undefined.
\begin{note} For temporaries, see~\ref{class.temporary}. \end{note} Transfer out of a loop, out of a block, or back
past an initialized variable with automatic storage duration involves the
destruction of objects with automatic storage duration that are in
scope at the point transferred from but not at the point transferred to.
(See~\ref{stmt.dcl} for transfers into blocks).
Expand Down