|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Xen Coding style and clang-format
On 31/07/2019 12:16, Viktor Mitin wrote: On Mon, Jul 29, 2019 at 3:35 PM Julien Grall <julien.grall@xxxxxxx> wrote:On 7/29/19 1:21 PM, Viktor Mitin wrote:On Mon, Jul 29, 2019 at 1:49 PM Julien Grall <julien.grall@xxxxxxx> wrote:On 7/29/19 10:13 AM, Viktor Mitin wrote:On Fri, Jul 26, 2019 at 3:50 PM Julien Grall <julien.grall@xxxxxxx> wrote: That's clang-format configuration not a write-up easily readable by human. It is also does not say what will happen for the rest of the things not configured (if there are any). As I pointed out in a different thread, it woudl be easier to start from an existing coding style (LLVM, BSD...) and decide whether you want to fully adopt it or make changes. So someone needs to be pick one and look at the difference in style with Xen. It seems you already done that job as you tweak it for Xen. Do you have a write-up of the differences?Yes, it is done exactly this way you mentioned. New 'xen' format style is based on 'llvm'. Can you give a link to this write-up in a human readable way? I am not sure why clang-format decided to format like that. Do you know why?The reason is that there are two strings in one line. It would not change it if it were not "arm,psci-1.0""\0", but "arm,psci-1.0\0".I would like to see the exact part of the clang-format coding style documentation that mention this requirements... The more that in an example above (copied below for simplicity), there are two strings in on line.The closest found seems BinPackParameters BinPackArguments, however, it is about function calls according to manual...Above, you mention the work is based on the LLVM coding style. Is there anything in that coding style about the string?Well, not much. See clang-format configurator mentioned above. However, there is a useful clang BreakStringLiterals option. It should be turned off to follow your suggestion not to break string literal for grep use case. I am not speaking about clang-format itself but the LLVM coding style. I assume there is a human readable coding style for LLVM, right? If so, is there any section in it about string?
This does not answer to my question. You pointed me how clang-format is configured, not how the behavior of clang format for this particular case and the developer documentation related to this. Cheers, -- Julien Grall _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |