This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 119a. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2026-01-21


3151. Closure types that are final

Section: 7.5.6.2  [expr.prim.lambda.closure]     Status: open     Submitter: Jay Ghiron     Date: 2025-12-25

(From submission #832.)

The current specification leaves open the possibility that an implementation declares closure types as final. That is undesirable.

Possible resolution:

Change in 7.5.6.2 [expr.prim.lambda.closure] paragraph 4 as follows:

The closure type is not an aggregate type (9.5.2 [dcl.init.aggr]) and is not final (11.1 [class.pre]); it is a structural type (13.2 [temp.param]) if and only if the lambda has no lambda-capture.