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

Function _get_required_header

ci/lint_cpp/is_header_include_checker.py:53–58  ·  view source on GitHub ↗

Map an FL_IS_* macro to its required is_*.h header via longest-prefix match.

(fl_is_macro: str)

Source from the content-addressed store, hash-verified

51
52
53def _get_required_header(fl_is_macro: str) -> str | None:
54 """Map an FL_IS_* macro to its required is_*.h header via longest-prefix match."""
55 for prefix in _SORTED_PREFIXES:
56 if fl_is_macro.startswith(prefix):
57 return FL_IS_PREFIX_TO_HEADER[prefix]
58 return None
59
60
61def _extract_fl_is_macros_on_preprocessor_lines(lines: list[str]) -> set[str]:

Callers 15

test_avr_generalMethod · 0.90
test_avr_subfamilyMethod · 0.90
test_esp32Method · 0.90
test_esp_32s3Method · 0.90
test_stm32Method · 0.90
test_teensy_4xMethod · 0.90
test_samd21Method · 0.90
test_sam_not_samdMethod · 0.90
test_nrf52Method · 0.90
test_rpMethod · 0.90
test_wasmMethod · 0.90

Calls

no outgoing calls

Tested by 15

test_avr_generalMethod · 0.72
test_avr_subfamilyMethod · 0.72
test_esp32Method · 0.72
test_esp_32s3Method · 0.72
test_stm32Method · 0.72
test_teensy_4xMethod · 0.72
test_samd21Method · 0.72
test_sam_not_samdMethod · 0.72
test_nrf52Method · 0.72
test_rpMethod · 0.72
test_wasmMethod · 0.72