From 118d466716ca688e3d1f5857cf8ea35b23c8e704 Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Sun, 30 Aug 2020 02:59:42 +0200 Subject: diff_options: Add doc comments --- src/diff_options.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/diff_options.rs b/src/diff_options.rs index 1b6fe76..571fe63 100644 --- a/src/diff_options.rs +++ b/src/diff_options.rs @@ -14,6 +14,7 @@ // along with this program. If not, see . +/// Git diff options. static FLAGS: [&'static str; 97] = [ "--abbrev", "--anchored", @@ -115,6 +116,9 @@ static FLAGS: [&'static str; 97] = [ ]; +/// Parse Git diff options from `args`. +/// +/// Returns a tuple containing `(args-that-are-not-diff-options, diff-options)`. pub fn parse(args: &[String]) -> (Vec<&String>, Vec<&String>) { let mut program_args = Vec::new(); let mut diff_args = Vec::new(); -- cgit v1.2.3