MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / _line_indent

Function _line_indent

scripts/code-verify.py:617–620  ·  view source on GitHub ↗

Return the count of leading whitespace columns on `line` (tabs count as one column — the codebase uses spaces, so this is a simple len-diff).

(line: str)

Source from the content-addressed store, hash-verified

615
616
617def _line_indent(line: str) -> int:
618 """Return the count of leading whitespace columns on `line` (tabs count
619 as one column — the codebase uses spaces, so this is a simple len-diff)."""
620 return len(line) - len(line.lstrip())
621
622
623def _find_brace_free_body_end(lines: list[str], control_idx: int) -> int | None:

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected