14inline bool parse_csv_row(
const std::string &line, std::vector<std::string> &fields)
20 for (std::size_t index = 0; index < line.size(); ++index) {
21 const char character = line[index];
22 if (character ==
'"') {
23 if (quoted && index + 1 < line.size() && line[index + 1] ==
'"') {
29 }
else if (character ==
',' && !quoted) {
30 fields.push_back(field);
32 }
else if (character !=
'\r') {
36 fields.push_back(field);