> On 16 Dec 2022, at 18:25, Edwin Török <edvin.to...@citrix.com> wrote: > > See CODING_STYLE: Xen uses spaces, not tabs. > > * OCaml code: > > Using `ocp-indent` for now to just make minimal modifications in > tabs vs spaces and get the right indentation. > We can introduce `ocamlformat` later. > > * C stubs: > > just replace tabs with spaces now, using `indent` or `clang-format` > would change code too much for 4.17. > > This avoids perpetuating a formatting style that is inconsistent with > the rest of Xen, and that makes preparing and submitting patches more > difficult (OCaml indentation tools usually only support spaces, not tabs). > > No functional change. > > Signed-off-by: Edwin Török <edvin.to...@citrix.com>
Acked-by: Christian Lindig <christian.lin...@citrix.com> I am in favour of automating the code formatting, and moving to OCamlformat in particular. The main drawback is that it can make back porting more difficult because formatting can change not just indentation but placement of parentheses and similar grouping syntax as well, leading to changes between the current code and older code that have to me resolved manually. — C