Skip to main content

wrappers_file_content

Function wrappers_file_content 

Source
fn wrappers_file_content(body: &str) -> String
Expand description

The complete wrappers file for a finished body: the marker line, a line naming the miniextendr-api version that generated it and an FNV-1a 64 digest of the body, then the body (#1552).

The digest is taken over normalize_source_locs(body), the same view wrappers_semantically_equal compares, so a Rust edit that only shifts line numbers leaves the header alone and the no-rewrite check keeps holding; any change to wrapper code, exports or docstrings changes it. It lets a reviewer or a build tool tell two copies of the file apart from the first two lines instead of diffing ~40k lines, and identifies the generator version when a shipped wrapper is reported against.