search for: indent_depth

Displaying 3 results from an estimated 3 matches for "indent_depth".

2019 Aug 11
5
[PATCH 1/2] Rust bindings: Add long description
...le changed, 10 insertions(+) diff --git a/generator/rust.ml b/generator/rust.ml index 1f5cefa62..3a07c3b53 100644 --- a/generator/rust.ml +++ b/generator/rust.ml @@ -52,6 +52,14 @@ let translate_bad_symbols s = else s +(* output longdesc to the rust file *) +let pr_longdesc name longdesc indent_depth = + let l = pod2text name longdesc in + List.iter (fun x -> + indent indent_depth; + pr "/// %s\n" x; + ) l + let generate_rust () = generate_header ~copyrights CStyle LGPLv2plus; @@ -398,6 +406,8 @@ extern \"C\" { style = (ret, args, optargs)...
2019 Aug 12
0
Re: [PATCH 1/2] Rust bindings: Add long description
...nerator/rust.ml b/generator/rust.ml > index 1f5cefa62..3a07c3b53 100644 > --- a/generator/rust.ml > +++ b/generator/rust.ml > @@ -52,6 +52,14 @@ let translate_bad_symbols s = > else > s > > +(* output longdesc to the rust file *) > +let pr_longdesc name longdesc indent_depth = indent_depth seems always 1, so I'd say to hardcode this indentation level for now (it can be always changed). > + let l = pod2text name longdesc in Better specify a width, so indent + comment + text does not overflow the recommended line limit of 100 characters: https://rust-lang.gith...
2019 Aug 13
2
Re: [PATCH 1/2] Rust bindings: Add long description
...ml >> index 1f5cefa62..3a07c3b53 100644 >> --- a/generator/rust.ml >> +++ b/generator/rust.ml >> @@ -52,6 +52,14 @@ let translate_bad_symbols s = >> else >> s >> >> +(* output longdesc to the rust file *) >> +let pr_longdesc name longdesc indent_depth = > > indent_depth seems always 1, so I'd say to hardcode this indentation > level for now (it can be always changed). OK. > >> + let l = pod2text name longdesc in > > Better specify a width, so indent + comment + text does not overflow > the recommended line l...