```
Base::Join(',', reply, [] -> bool (map<string,string>::const_reference item, std::ostream &out) {
  out << quoted(item.first) << ':' << quoted(item.second);
}, Strm);
```

That seems relatively straightforward to me. you could use 'auto' possibly for the first parameter of the template rather than explicit type. Also harder to get wrong and easier to read than the state machine.