(header: &str)
| 2613 | } |
| 2614 | |
| 2615 | fn private_libcpp_header_recommendation(header: &str) -> &'static str { |
| 2616 | if let Some((_, recommendation)) = PRIVATE_LIBCPP_HEADER_MAPPINGS_RS |
| 2617 | .iter() |
| 2618 | .find(|(candidate, _)| *candidate == header) |
| 2619 | { |
| 2620 | return *recommendation; |
| 2621 | } |
| 2622 | PRIVATE_LIBCPP_HEADER_MAPPINGS_RS |
| 2623 | .iter() |
| 2624 | .find_map(|(prefix, recommendation)| header.starts_with(prefix).then_some(*recommendation)) |
| 2625 | .unwrap_or("\"appropriate FastLED header\" (check ci/iwyu/stdlib.imp)") |
| 2626 | } |
| 2627 | |
| 2628 | fn banned_header_matches_exception(file_path: &str, header: &str) -> bool { |
| 2629 | let normalized = normalize_path(file_path); |
no test coverage detected