pub fn apply_diff(result: &DiffResult) -> AppResult<usize>Expand description
Applies selected diff entries to their files.
Each file’s accepted entries are turned back into suggestions and applied
through apply_suggestions, so the result is collision-safe and preserves
comments and formatting — identical to the fix command.
§Arguments
result- Selected diff entries grouped by file
§Returns
AppResult<usize> - Number of line changes written across all files
§Errors
Returns an error if reading or writing a file fails.