Skip to main content

looks_generated

Function looks_generated 

Source
pub fn looks_generated(source: &str, path: &Path) -> bool
Expand description

True if a file looks machine-generated and should be skipped.

Generated code parses fine, but its symbols are noise in an impact graph: nobody edits it by hand, and it is regenerated wholesale rather than refactored. Shared across adapters so every language applies the same rule.

Only the first few lines are inspected — the convention across generators (protoc, bindgen, go generate, OpenAPI) is a banner comment at the top.