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

2024-03-20


839. sizeof with opaque enumerations

Section: 7.6.2.5  [expr.sizeof]     Status: dup     Submitter: Alberto Ganesh Barbati     Date: 9 March, 2009

7.6.2.5 [expr.sizeof] paragraph 1 says,

The sizeof operator shall not be applied... to an enumeration type before all its enumerators have been declared...

This prevents use of sizeof with an opaque enumeration type, even though the underlying type of such enumerations is known.

Rationale (May, 2009):

Duplicate of issue 803.