The following nested typedef works:
struct FOOO
{
struct TRAITS
{
using size_type = std::uint32_t;
};
void func(TRAITS::size_type arg) { } // This works fine if FOOO is not a template class.
};
However, if I make FOOO a template class, it doesn't work:
template <typename T>
struct FOOO
{
struct TRAITS
{
using size_type = std::uint32_t;
};
void func(TRAITS::size_type arg) { } // This works fine if FOOO is not a template class.
};
//syntax error: identifier 'size_type'
I'm wondering why this is, I can't make sense of it. I am on Visual Studio 2019.