| 98 | //! Map lookup helper. |
| 99 | template <typename Map, typename Key> |
| 100 | auto FindKey(Map&& map, Key&& key) -> decltype(&map.at(key)) |
| 101 | { |
| 102 | auto it = map.find(key); |
| 103 | return it == map.end() ? nullptr : &it->second; |
| 104 | } |
| 105 | |
| 106 | } // namespace util |
| 107 |
no test coverage detected