Accessing the value_type of a specific vector.
Does anyone know if there is a way to make something like...
1 2
|
vector<int> v{};
using vtype = v.value_type;
|
work? Thanks in advance!
Last edited on
1 2 3 4
|
std::vector<int> v{};
using vtype = std::vector<int>::value_type;
using vtype = decltype(v)::value_type;
|
I appreciate it sir. I'm unfamiliar wit the uses of decltype.
Topic archived. No new replies allowed.