| 169 | } |
| 170 | |
| 171 | std::optional<unsigned long> toUnsigned(const std::string &text) |
| 172 | { |
| 173 | try |
| 174 | { |
| 175 | auto index = std::stoul(text); |
| 176 | return index; |
| 177 | } |
| 178 | catch (...) |
| 179 | { |
| 180 | return {}; |
| 181 | } |
| 182 | } |
| 183 | |
| 184 | } // namespace functions |
no outgoing calls
no test coverage detected