Skip to content

Codebase intelligence for AI and humans: code health scores, auto-generated docs, git analytics, dead code detection, and architectural decisions via MCP.

docs(health): point the complexity README at ast_utils.self_member_name (#4169)

wang2-latfeeeef7d798c
diff --git a/packages/core/src/repowise/core/analysis/health/complexity/README.md b/packages/core/src/repowise/core/analysis/health/complexity/README.md
index 1ac969c8b..112d271e9 100644
--- a/packages/core/src/repowise/core/analysis/health/complexity/README.md
+++ b/packages/core/src/repowise/core/analysis/health/complexity/README.md
@@ -161,13 +161,16 @@ fields on its `LanguageNodeMap` (all default to empty = opt-out):
field reads and method calls).
The receiver and member-name children are extracted by a generic
-field-name probe (`class_analysis._self_member_name`), which tries the
-`object`/`value`/`argument`/`expression` (receiver) and
-`property`/`attribute`/`field`/`name` (member) fields and then falls back
-to positional children — so most tree-sitter grammars need only the
-node-type names above. Get one wrong and the safety valve degrades the
-class to "no signal" rather than emitting a false positive, so it's cheap
-to add a language speculatively and refine later.
+field-name probe (`ast_utils.self_member_name`, built on `member_object`
+and `member_name`). `member_object` tries the
+`object`/`value`/`argument`/`operand`/`expression` fields and falls back
+to the first named child. `member_name` tries the
+`property`/`attribute`/`field`/`name` fields, then Swift's nested
+`suffix`, then the last named `*identifier` child — so most tree-sitter
+grammars need only the node-type names above. Get one wrong and the
+safety valve degrades the class to "no signal" rather than emitting a
+false positive, so it's cheap to add a language speculatively and refine
+later.
For **assertion-block** detection (test-quality smells), set two more
opt-in fields: