This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 112c. See for the official list.


1400. Function pointer equality

Section: 7.6.10  [expr.eq]     Status: NAD     Submitter: Nikolay Ivchenkov     Date: 2011-09-30

According to 7.6.10 [expr.eq] paragraph 2, two function pointers only compare equal if they point to the same function. However, as an optimization, implementations are currently aliasing functions that have identical definitions. It is not clear whether the Standard needs to deal explicitly with this optimization or not.

Rationale (February, 2012):

The Standard is clear on the requirements, and implementations are free to optimize within the constraints of the “as-if” rule.