chiavdf icon indicating copy to clipboard operation
chiavdf copied to clipboard

Add clang-format

Open dannywillems opened this issue 2 years ago • 4 comments

Dump .clang-format using:

clang-format -style=llvm -dump-config > .clang-format

and set SortIncludes to false

Run clang-format version 13.0.1-3+b1 on src/h src/.cpp src/.hpp src/.c

dannywillems avatar Mar 25 '22 10:03 dannywillems

Rebased on main, splitted in two commits: one adding clang-format file and one executing clang-format.

dannywillems avatar Mar 28 '22 12:03 dannywillems

'This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed.'

github-actions[bot] avatar May 28 '22 11:05 github-actions[bot]

@dannywillems I'm generally in favor of using clang format. I think the main benefit from it comes from requiring the canonical format in CI, which this patch does not introduce. This will become outdated very quickly after landing. There would probably need to be some documentation for committers how to apply the clang format before pushing a PR.

I would also have expected the clang format config to somewhat match the existing format. Most importantly, use 4 spaces for indentation rather than 2. Ideally, the change to the source code diff should be as small as possible.

arvidn avatar Oct 06 '22 21:10 arvidn

'This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed.'

github-actions[bot] avatar Dec 07 '22 11:12 github-actions[bot]

Closing abandoned PR

emlowe avatar May 13 '24 23:05 emlowe