MCPcopy Create free account
hub / github.com/FastLED/FastLED / banned_subpath_replacement

Function banned_subpath_replacement

ci/lint_cpp_rs/src/lib.rs:2431–2439  ·  view source on GitHub ↗
(include_path: &str)

Source from the content-addressed store, hash-verified

2429}
2430
2431fn banned_subpath_replacement(include_path: &str) -> Option<String> {
2432 BANNED_INTERNAL_SUBPATHS
2433 .iter()
2434 .find_map(|(banned_prefix, replacement_prefix)| {
2435 include_path
2436 .strip_prefix(banned_prefix)
2437 .map(|suffix| format!("{replacement_prefix}{suffix}"))
2438 })
2439}
2440
2441fn is_valid_include_path(include_path: &str) -> bool {
2442 if is_top_level_include(include_path) || is_external_sdk_header(include_path) {

Callers 2

is_valid_include_pathFunction · 0.85
check_file_contentMethod · 0.85

Calls 1

mapMethod · 0.45

Tested by

no test coverage detected