後にメンバー型を取得しdecltype、 variable を定義しようとしていますy。
struct s
{
typedef int val_type;
};
int main()
{
s x;
decltype(x)::val_type y;
}
上記のプログラムでは、Microsoft VS2013 プレビュー C++ コンパイラが次のように警告します。
'val_type' : is not a member of '`global namespace''
ただし、decltype(x)type を取得しますs。val_typeメンバータイプを取得するためにそれをたどることができなかったのはなぜですか?