| 78 | } |
| 79 | |
| 80 | void assert_simple_edge_chains( |
| 81 | const std::unordered_map<size_t, size_t>& valance) { |
| 82 | for (auto item : valance) { |
| 83 | if (item.second != 1 && item.second != 2) { |
| 84 | std::stringstream err_msg; |
| 85 | err_msg << "Complex edge loop detected! "; |
| 86 | err_msg << "Vertex " << item.first << " has valance " << item.second |
| 87 | << std::endl; |
| 88 | throw RuntimeError(err_msg.str()); |
| 89 | } |
| 90 | } |
| 91 | } |
| 92 | } |
| 93 | using namespace EdgeUtilsHelper; |
| 94 |
no test coverage detected