| 23 | } |
| 24 | |
| 25 | OptionsMap stringToOptions(const std::string& optionsString) |
| 26 | { |
| 27 | OptionsMap result; |
| 28 | for (auto it : std::views::split(optionsString, ' ')) |
| 29 | { |
| 30 | std::string left(&*it.begin(), std::ranges::distance(it)); |
| 31 | std::string right; |
| 32 | auto i = left.find('='); |
| 33 | if (i != std::string::npos) |
| 34 | { |
| 35 | right = left.substr(i + 1); |
| 36 | left = left.substr(0, i); |
| 37 | } |
| 38 | result[left] = right; |
| 39 | } |
| 40 | return result; |
| 41 | } |
| 42 | |
| 43 | std::string optionsToString(const OptionsMap& options) |
| 44 | { |
no test coverage detected