433. Contradiction in specification of unexpected()

Section: 99 [unexpected] Status: NAD Submitter: Vyatcheslav Sysoltsev Opened: 2003-09-29 Last modified: 2016-02-10

Priority: Not Prioritized

View all issues with NAD status.


Clause [except.unexpected] paragraph 1 says that "void unexpected(); is called (18.7.2) immediately after completing the stack unwinding for the former function", but (Effects) says that "void unexpected(); . . . Calls the unexpected_handler function in effect immediately after evaluating the throwexpression (,". Isn't here a contradiction: 15.5.2 requires stack have been unwound when in void unexpected() and therefore in unexpected_handler but claims that unexpected_handler is called "in effect immediately" after evaluation of throw expression is finished, so there is no space left for stack to be unwound therefore? I think the phrase "in effect immediately" should be removed from the standard because it brings ambiguity in understanding.

Proposed resolution:


There is no contradiction. The phrase "in effect immediately" is just to clarify which handler is to be called.