999. Taking the address of a function

Section: 23.10.11 [specialized.algorithms] Status: C++11 Submitter: Peter Dimov Opened: 2009-03-09 Last modified: 2016-02-10

Priority: Not Prioritized

View all other issues in [specialized.algorithms].

View all issues with C++11 status.


The same fix (reference 987) may be applied to addressof, which is also constrained to ObjectType. (That was why boost::ref didn't work with functions - it tried to apply boost::addressof and the reinterpret_cast<char&> implementation of addressof failed.)

[ Batavia (2009-05): ]

We agree.

Move to Tentatively Ready.

[ 2009-07 Frankfurt ]

Moved from Tentatively Ready to Open only because the wording needs to be tweaked for concepts removal.

[ 2009-10-10 Daniel updates wording to concept-free. ]

[ 2009-10 post-Santa Cruz: ]

Move to Tentatively Ready.

Proposed resolution:

[ The resolution assumes that addressof is reintroduced as described in n2946 ]

In 23.10.11 [specialized.algorithms] change as described:

template <class T> T* addressof(T& r);

Returns: The actual address of the object or function referenced by r, even in the presence of an overloaded operator&.