JonathanSalwan / Triton

Triton is a dynamic binary analysis library. Build your own program analysis tools, automate your reverse engineering, perform software verification or just emulate code.
https://triton-library.github.io
Apache License 2.0
3.4k stars 524 forks source link

Clang format #1273

Open ZehMatt opened 10 months ago

ZehMatt commented 10 months ago

I've tried to minimize the diff but also didn't want to exactly match it to get somewhere in the middle of readability and consistency. I also enabled the option to auto comment the end of the namespace, this is a bit inconsistent at the moment and we should either turn that option off or remove the ones that don't fit, I personally think its best to let clang-format do the commenting so it won't be missed and it will be consistent across the board.

Probably need a few more files I should look into, clang-format can get quite notorious about tables.

SweetVishnya commented 10 months ago

We could also add clang-format checks to CI

ZehMatt commented 10 months ago

We could also add clang-format checks to CI

I could do that but its best to have all of the files formatted first

JonathanSalwan commented 10 months ago

Thanks for this MR,

I could do that but its best to have all of the files formatted first

Before updating all files, we should first agree on a format :). I will play with the example you provided and get back to you as soon as I can.

ZehMatt commented 10 months ago

Before updating all files, we should first agree on a format :).

Definitely, that is also what I meant.

I will play with the example you provided and get back to you as soon as I can.

No rush here, thanks for looking into it.

cnheitman commented 10 months ago

This is a nice addition :)

@ZehMatt Could you modify the PR so it merges into dev-v1.0 instead of master?

ZehMatt commented 10 months ago

This is a nice addition :)

@ZehMatt Could you modify the PR so it merges into dev-v1.0 instead of master?

Not sure why GitHub decided to pick master, I branched off dev-1.0 🤷‍♂️ , changed it.

cnheitman commented 10 months ago

Thanks, @ZehMatt !