Map an FL_IS_* macro to its required is_*.h header via longest-prefix match.
(fl_is_macro: str)
| 51 | |
| 52 | |
| 53 | def _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 | |
| 61 | def _extract_fl_is_macros_on_preprocessor_lines(lines: list[str]) -> set[str]: |
no outgoing calls