| 90 | } |
| 91 | |
| 92 | std::string readNextNonEmptyLine(std::ifstream &file) { |
| 93 | std::string result = ""; |
| 94 | // Using a for loop to read the next non empty line |
| 95 | for (std::string line; std::getline(file, line);) { |
| 96 | result += line; |
| 97 | if (result != "") break; |
| 98 | } |
| 99 | // If no file has been found, throw an exception |
| 100 | if (result == "") { |
| 101 | throw std::runtime_error("Non empty lines not found in the file"); |
| 102 | } |
| 103 | return result; |
| 104 | } |
| 105 | |
| 106 | std::string getBackendName(bool lower) { |
| 107 | af::Backend backend = af::getActiveBackend(); |
no outgoing calls
no test coverage detected