| 2 | #include <iostream> |
| 3 | |
| 4 | constexpr bool isLarge(double value) |
| 5 | { |
| 6 | using namespace matchit; |
| 7 | return match(value)( |
| 8 | // clang-format off |
| 9 | pattern | app(_ * _, _ > 1000) = expr(true), |
| 10 | pattern | _ = expr(false) |
| 11 | // clang-format on |
| 12 | ); |
| 13 | } |
| 14 | |
| 15 | // app with projection returning scalar types is supported by constexpr match. |
| 16 | static_assert(isLarge(100)); |
no test coverage detected