| Re: How to convert a pointer to member function type to a const member one |
|
 |
|
 |
|
 |
|
 |
Group: comp.lang.c++.moderated · Group Profile
Author: Roman.PerepelitsaRoman.Perepelitsa Date: May 7, 2008 09:10
On 6 May, 20:47, mcostalba gmail.com> wrote:
> Anyhow here is my much simpler solution...so simple that is probably
> broken in some way, but I cannot find where:
> [cut]
> BTW it seems to work.
Seems like it does not work for functions (always returns false for
them)
and it's not that smart with regard to const objects and const
methods.
Here is how original is_call_possible works:
struct foo {
void operator()();
};
struct bar {
void operator()() const;
};
assert(is_call_possible::value);
assert(!is_call_possible::value);
assert(is_call_possible::value);
assert(is_call_possible::value);
But maybe you don't need this functionality...
Roman Perepelitsa.
|