Skip to content
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

apply updated code style #1196

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft

Conversation

apolyakov
Copy link
Contributor

No description provided.

@apolyakov apolyakov added the refactoring Logic and code style improvements label Dec 20, 2024
@apolyakov apolyakov added this to the next milestone Dec 20, 2024
@apolyakov apolyakov self-assigned this Dec 20, 2024
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

after squash, there will be another sha commit. .git-blame-ignore-revs should be added after the merge of this MR

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it's added here so you can test it and make sure that git blame continues working

@@ -3,12 +3,12 @@
#include "common/smart_ptrs/intrusive_ptr.h"

#ifndef INCLUDED_FROM_KPHP_CORE
#error "this file must be included only from runtime-core.h"
#error "this file must be included only from runtime-core.h"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't want to enable `IndentPPDirectives'?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 for macro indentation

AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: Empty
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe we should keep it?

ReflowComments: true
SortIncludes: true
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword: false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd keep it. IMHO

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Includes are sorted implicitly by setting base variant on LLVM, I suppose.

IncludeCategories:
- Regex: '^<'
Priority: 1
IndentCaseLabels: true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe we should keep it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mb will we add the formatting script first, and then the new rules?

@@ -3,12 +3,12 @@
#include "common/smart_ptrs/intrusive_ptr.h"

#ifndef INCLUDED_FROM_KPHP_CORE
#error "this file must be included only from runtime-core.h"
#error "this file must be included only from runtime-core.h"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 for macro indentation

ReflowComments: true
SortIncludes: true
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword: false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Includes are sorted implicitly by setting base variant on LLVM, I suppose.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactoring Logic and code style improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants