| 12 | |
| 13 | #if __cpp_using_enum |
| 14 | constexpr std::string_view to_string(Permission permission) |
| 15 | { |
| 16 | switch(permission) { |
| 17 | using enum Permission; // #A New use of using |
| 18 | case Read: return "Read"; |
| 19 | case Write: return "Write"; |
| 20 | case Execute: return "Execute"; |
| 21 | } |
| 22 | |
| 23 | return "unknown"; |
| 24 | } |
| 25 | |
| 26 | int main() |
| 27 | { |
no outgoing calls
no test coverage detected