是否可以使用已经存在的变量作为返回值的目标structured bindings
?
auto f()
{
return std::make_tuple(1,2.2);
}
int main()
{
int x;
double z;
[ x, z ] = f(); // Did not work in gcc 7.1
// structured bindings only work with "new" vars?
auto [a, b] = f(); // works fine
}