Created on 2010-09-02.00:00:00 last changed 130 months ago
[Voted into the WP at the March, 2011 meeting.]
Proposed resolution (November, 2010):
Change 7.7 [expr.const] bullet 2.19 as follows:
It's not clear whether the current rules for constant expressions allow indirect calls of constexpr functions and constexpr member functions; for example,
constexpr bool is_negative(int x) { return x < 0; } constexpr bool check(int x, bool (*p)(int)) { return p(x); } static_assert(check(-2, is_negative), "Error");
If this is to be permitted, there does not seem to be a reason to prohibit equality comparison of pointers to functions or pointers to objects of static storage duration -- these can be tracked as is already done for non-type template parameters.
History | |||
---|---|---|---|
Date | User | Action | Args |
2014-03-03 00:00:00 | admin | set | status: fdis -> c++11 |
2011-04-10 00:00:00 | admin | set | messages: + msg3319 |
2011-04-10 00:00:00 | admin | set | status: ready -> fdis |
2010-11-29 00:00:00 | admin | set | messages: + msg3052 |
2010-11-29 00:00:00 | admin | set | status: open -> ready |
2010-09-02 00:00:00 | admin | create |