Skip to content

[clang-format] Add BreakBeforeInlineASMColon and BreakBeforeStructInitialization configurations #273

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

NastyaVicodin
Copy link
Contributor

We are trying to use the clang-format approach as a base for Xen [1] style formatting.
During the state of testing clang-format with different configurations, we found that some points regarding the Xen coding style are not configurable. Therefore, we decided to add them to be able to make a choice in different cases.

[1] - https://xenproject.org/

Anastasiia Lukianenko added 2 commits November 19, 2020 12:20
If ``true``, struct left brace will be placed after line breaks.
true:
struct new_struct struct_name =
{...};

false:
struct new_struct struct_name = {
...};

Signed-off-by: Anastasiia Lukianenko <[email protected]>
If ``true``, colons in ASM parameters will be placed after line breaks.
true:
asm volatile("loooooooooooooooooooooooooooooooooooooooooooooong",
             :
             : val);
false:
asm volatile("loooooooooooooooooooooooooooooooooooooooooooooong",
             : : val);

Signed-off-by: Anastasiia Lukianenko <[email protected]>
@repo-lockdown
Copy link

repo-lockdown bot commented Nov 19, 2020

This repository does not accept pull requests. Please follow http://llvm.org/docs/Contributing.html#how-to-submit-a-patch for contribution to LLVM.

@repo-lockdown repo-lockdown bot closed this Nov 19, 2020
@repo-lockdown repo-lockdown bot locked and limited conversation to collaborators Nov 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant