|
Boost : |
From: Rani Sharoni (rani_sharoni_at_[hidden])
Date: 2003-01-13 08:04:16
"Paul Mensonides" <pmenso57_at_[hidden]> wrote in message
news:000701c2b9fd$f56ef7f0$9d00a8c0_at_c161550b...
> Is this well-formed:
>
> struct X {
> typedef void func_t(int);
> func_t member;
> };
>
> void X::member(int) {
> return;
> }
>
> What about:
>
> struct X {
> typedef void func_t(int) const;
> // ^^^^^
> func_t member;
> };
>
> void X::member(int) const {
> return;
> }
>
Both are well-formed. See 8.3.5/4,7
> This is the root of my question:
>
> template<class> struct test;
>
> template<class R, class C> struct test<R C::*> {
> typedef R type;
> };
>
> struct X { };
>
> test< void (X::*)(int) >::type // what type is this?
>
> Is it a function type, or is it a "member function type"?
>
Judging, again, by 8.3.5/4,7 it's a function type.
Rani
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk