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

[MATLAB] Enable clang-format in the matlab/ subfolder. #35941

Closed
sgilmore10 opened this issue Jun 6, 2023 · 1 comment
Closed

[MATLAB] Enable clang-format in the matlab/ subfolder. #35941

sgilmore10 opened this issue Jun 6, 2023 · 1 comment

Comments

@sgilmore10
Copy link
Member

sgilmore10 commented Jun 6, 2023

Describe the enhancement requested

Currently, there is no specific format that is enforced for the C++ code in the MATLAB interface. This makes it easy to make accidental formatting mistakes and leads to inconsistent code formatting (e.g. #38189 (comment)).

We should use clang-format on the source files in the matlab/ subfolder.

Component(s)

MATLAB

kou added a commit to kou/arrow that referenced this issue Mar 16, 2024
kevingurney pushed a commit that referenced this issue Mar 19, 2024
…40588)

### Rationale for this change

If we use formatter, we don't need to check style manually.

### What changes are included in this PR?

* Add clang-format configuration to pre-commit
* This uses the same style as C++/Python/R uses

We can format by `pre-commit run -a`.
 
### Are these changes tested?

Yes.

### Are there any user-facing changes?

No.
* GitHub Issue: #35941

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Kevin Gurney <kgurney@mathworks.com>
@kevingurney
Copy link
Member

Issue resolved by pull request 40588
#40588

@kevingurney kevingurney added this to the 16.0.0 milestone Mar 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants