Skip to main content

dominant_identifier

Function dominant_identifier 

Source
pub fn dominant_identifier(group: &CloneGroup) -> Option<String>
Expand description

Best-effort name for the extracted function, derived from the most frequent non-generic identifier in the representative fragment.

Returns None when the dominant identifier is generic (data, result, loop counters), appears only once, or ties with another, so absence is the low-confidence signal for both human and agent consumers. This is a lexical heuristic over the raw fragment, not an AST analysis; it is advisory and consumers should verify before applying.