Another alternative is to use an std::tie:
int b, c;
std::tie(std::ignore, b, c) = foo();
Edit
As mentioned in the comments, there are some issues with this approach:
- No type inference possible
- The objects must be constructed before, so unless the default constructors are trivial, it’s not a good alternative.