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

Function _get_line_number

ci/lint_cpp/test_unity_build.py:239–241  ·  view source on GitHub ↗

Get the line number for a match position in file content.

(content: str, match_start: int)

Source from the content-addressed store, hash-verified

237
238
239def _get_line_number(content: str, match_start: int) -> int:
240 """Get the line number for a match position in file content."""
241 return content[:match_start].count("\n") + 1
242
243
244def _check_build_hpp_naming(src_dir: Path) -> list[str]:

Calls 1

countMethod · 0.45

Tested by

no test coverage detected