This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of C++11 status.

### 894. longjmp and destructors

Section: 17.14 [support.runtime] Status: C++11 Submitter: Lawrence Crowl, Alisdair Meredith Opened: 2008-09-17 Last modified: 2016-01-28

Priority: Not Prioritized

View all other issues in [support.runtime].

View all issues with C++11 status.

Discussion:

The interaction between `longjmp` and exceptions seems unnecessarily restrictive and not in keeping with existing practice.

Proposed resolution:

Edit paragraph 4 of 17.14 [support.runtime] as follows:

> The function signature `longjmp(jmp_buf jbuf, int val)` has more restricted behavior in this International Standard. A `setjmp/longjmp` call pair has undefined behavior if replacing the `setjmp` and `longjmp` by `catch` and `throw` would destroy invoke any non-trivial destructors for any automatic objects.