i have a collection defined as -
using Parameters = std::vector<int>;
using Group = std::pair<std::string, Parameters>;
std::vector<Group> inputs;
intention is to use statement like -
inputs.push_back(group0 /*What goes in here ?*/);
inputs.push_back(group1 /*What goes in here ?*/);
How can i initialize group0
and group1
using initializer list ? A code like inputs.push_back(std::make_pair("group0", {1, 2, 3, 4}))
doesn't seem to work.
Aucun commentaire:
Enregistrer un commentaire