)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":7233,"name":"Matthew Oliver","email":"matt@oliver.net.au","username":"mattoliverau"},"change_message_id":"8975c6103e754a447b3d12f8dd0a4d3c4f0460b1","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":5,"id":"6827137c_0dde79f3","updated":"2026-03-08 23:18:51.000000000","message":"Also if we want to keep the default but still align values consecutively we can add a .clang-format file with just:\n\n```\n---\nAlignConsecutiveAssignments:\n  Enabled: true\n  AcrossEmptyLines: false # Set to true to align across empty lines\n  AcrossComments: false   # Set to true to align across comments\n```\n\nAnd it aligns, but still confirms to the default style otherwise:\n\n```\n--- i/include/erasurecode/erasurecode.h\n+++ w/include/erasurecode/erasurecode.h\n@@ -41,16 +41,16 @@ extern \"C\" {\n /* \u003d~\u003d*\u003d~\u003d\u003d~\u003d*\u003d~\u003d\u003d~\u003d*\u003d~\u003d Supported EC backends \u003d~\u003d*\u003d~\u003d\u003d~\u003d*\u003d~\u003d\u003d~\u003d*\u003d~\u003d\u003d~\u003d*\u003d~\u003d\u003d */\n \n typedef enum {\n-  EC_BACKEND_NULL \u003d 0,\n-  EC_BACKEND_JERASURE_RS_VAND \u003d 1,\n-  EC_BACKEND_JERASURE_RS_CAUCHY \u003d 2,\n-  EC_BACKEND_FLAT_XOR_HD \u003d 3,\n-  EC_BACKEND_ISA_L_RS_VAND \u003d 4,\n-  EC_BACKEND_SHSS \u003d 5,\n+  EC_BACKEND_NULL                   \u003d 0,\n+  EC_BACKEND_JERASURE_RS_VAND       \u003d 1,\n+  EC_BACKEND_JERASURE_RS_CAUCHY     \u003d 2,\n+  EC_BACKEND_FLAT_XOR_HD            \u003d 3,\n+  EC_BACKEND_ISA_L_RS_VAND          \u003d 4,\n+  EC_BACKEND_SHSS                   \u003d 5,\n   EC_BACKEND_LIBERASURECODE_RS_VAND \u003d 6,\n-  EC_BACKEND_ISA_L_RS_CAUCHY \u003d 7,\n-  EC_BACKEND_LIBPHAZR \u003d 8,\n-  EC_BACKEND_ISA_L_RS_VAND_INV \u003d 9,\n+  EC_BACKEND_ISA_L_RS_CAUCHY        \u003d 7,\n+  EC_BACKEND_LIBPHAZR               \u003d 8,\n+  EC_BACKEND_ISA_L_RS_VAND_INV      \u003d 9,\n   EC_BACKENDS_MAX,\n } ec_backend_id_t;\n```\n\nOr if we just want to confirm to say the gnu, mozilla, google, we can just add `-style\u003dgnu` or their style. If we wanted to go the linux kernel, then we can just grab their .clang-style file, I did try it and it works... just not sure it\u0027s the layout we want.\n\nEither way, the only real bocker I can see on this at the moment is the rpm bindep package","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":38767,"name":"Wael Halbawi","display_name":"Wael Halbawi","email":"whalbawi@nvidia.com","username":"whalbawi"},"change_message_id":"905327c986571bbe967b9a1e0d114250ccfb5bc9","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":5,"id":"b63f8bd7_b829a876","updated":"2026-03-10 17:49:05.000000000","message":"I think we should place a (potentially empty) `.clang-format` file in the repository\u0027s top-level directory. Otherwise, `clang-format` will climb-up the tree looking for one which may source unintended formatting rules:\n\n```\nwhalbawi@88d0bd4-lcedt:/repos/liberasurecode$ pwd\n/repos/liberasurecode\nwhalbawi@88d0bd4-lcedt:/repos/liberasurecode$ cat /.clang-format\nIndentWidth: 8\nwhalbawi@88d0bd4-lcedt:/repos/liberasurecode$ make check-format\n...\nConsider applying the following:\n\ndiff --git a/include/erasurecode/alg_sig.h b/include/erasurecode/alg_sig.h\nindex 1b81de9..b515247 100644\n--- a/include/erasurecode/alg_sig.h\n+++ b/include/erasurecode/alg_sig.h\n@@ -30,8 +30,8 @@ typedef int (*galois_single_multiply_func)(int, int, int);\n typedef void (*galois_uninit_field_func)(int);\n\n struct jerasure_mult_routines {\n-  galois_single_multiply_func galois_single_multiply;\n-  galois_uninit_field_func galois_uninit_field;\n+        galois_single_multiply_func galois_single_multiply;\n+        galois_uninit_field_func galois_uninit_field;\n };\nwhalbawi@88d0bd4-lcedt:/repos/liberasurecode$\n\n```","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"d7bb07d17556c7890dcaf92289d0c3540fb7b04d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":5,"id":"7819a251_1f3e4674","updated":"2026-03-10 19:26:47.000000000","message":"Thanks for the pointer, Wael!","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"3329a6d5cac1c4d11e7ea8382f8d934234c3ce6a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":5,"id":"c80ecfeb_dc4d919f","in_reply_to":"b63f8bd7_b829a876","updated":"2026-03-10 20:06:52.000000000","message":"Done","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":38767,"name":"Wael Halbawi","display_name":"Wael Halbawi","email":"whalbawi@nvidia.com","username":"whalbawi"},"change_message_id":"0192bd5fd624e7ed66ab1090affe0b915fce4953","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":5,"id":"8d0e5c5d_4b8b1871","in_reply_to":"c80ecfeb_dc4d919f","updated":"2026-03-10 20:51:49.000000000","message":"The only rule I would encourage placing here is `IndentWidth: 4`:\n- This is a C (as opposed to a C++) codebase so lines are reasonably short.\n- I suspect most readers of this codebase also read Python code, where 4 space indentation is common.\n\nHaving said that, I agree with @matt@oliver.net.au in that we should \"just pick\" a style and move on.","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":38767,"name":"Wael Halbawi","display_name":"Wael Halbawi","email":"whalbawi@nvidia.com","username":"whalbawi"},"change_message_id":"0192bd5fd624e7ed66ab1090affe0b915fce4953","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":7,"id":"2448658d_7bedf4fe","updated":"2026-03-10 20:51:49.000000000","message":"LGTM!","commit_id":"dc35a7527fff0701b5e480a7e39a561a117319f6"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"af003bc2cac6dab0ac293329dd230915dece0e0e","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":9,"id":"1d7ebf7f_d397e34d","updated":"2026-05-06 20:31:26.000000000","message":"Oh, right -- I should rebase this chain. Thanks for the fresh vote, though!\n\nI should maybe also play around with `.clang-format` options some more, too, see if I can get https://review.opendev.org/c/openstack/liberasurecode/+/977487 to be a *little* smaller than -3962 / +4100","commit_id":"9a745a603d9c7dc8754143a35c20e2650e2f82ae"}],"Makefile.am":[{"author":{"_account_id":38767,"name":"Wael Halbawi","display_name":"Wael Halbawi","email":"whalbawi@nvidia.com","username":"whalbawi"},"change_message_id":"905327c986571bbe967b9a1e0d114250ccfb5bc9","unresolved":true,"context_lines":[{"line_number":66,"context_line":"\tif ! find src include -type f -name \u0027*.[ch]\u0027 |  \\"},{"line_number":67,"context_line":"\t  grep -v \u0027include/config_liberasurecode\\.h\u0027 |  \\"},{"line_number":68,"context_line":"\t  xargs clang-format-18 -n -Werror ; then       \\"},{"line_number":69,"context_line":"\t    make format ;                               \\"},{"line_number":70,"context_line":"\t    echo ;                                      \\"},{"line_number":71,"context_line":"\t    echo Consider applying the following: ;     \\"},{"line_number":72,"context_line":"\t    echo ;                                      \\"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"f59fe7e5_9d5c384e","line":69,"updated":"2026-03-10 17:49:05.000000000","message":"I think `check-format` should not make changes to the tree, at least when run locally. `git clang-format --diff` can help here.","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"3329a6d5cac1c4d11e7ea8382f8d934234c3ce6a","unresolved":false,"context_lines":[{"line_number":66,"context_line":"\tif ! find src include -type f -name \u0027*.[ch]\u0027 |  \\"},{"line_number":67,"context_line":"\t  grep -v \u0027include/config_liberasurecode\\.h\u0027 |  \\"},{"line_number":68,"context_line":"\t  xargs clang-format-18 -n -Werror ; then       \\"},{"line_number":69,"context_line":"\t    make format ;                               \\"},{"line_number":70,"context_line":"\t    echo ;                                      \\"},{"line_number":71,"context_line":"\t    echo Consider applying the following: ;     \\"},{"line_number":72,"context_line":"\t    echo ;                                      \\"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"90b1229f_737e9525","line":69,"in_reply_to":"14b8a547_9bdbefd3","updated":"2026-03-10 20:06:52.000000000","message":"Done","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":38767,"name":"Wael Halbawi","display_name":"Wael Halbawi","email":"whalbawi@nvidia.com","username":"whalbawi"},"change_message_id":"0192bd5fd624e7ed66ab1090affe0b915fce4953","unresolved":false,"context_lines":[{"line_number":66,"context_line":"\tif ! find src include -type f -name \u0027*.[ch]\u0027 |  \\"},{"line_number":67,"context_line":"\t  grep -v \u0027include/config_liberasurecode\\.h\u0027 |  \\"},{"line_number":68,"context_line":"\t  xargs clang-format-18 -n -Werror ; then       \\"},{"line_number":69,"context_line":"\t    make format ;                               \\"},{"line_number":70,"context_line":"\t    echo ;                                      \\"},{"line_number":71,"context_line":"\t    echo Consider applying the following: ;     \\"},{"line_number":72,"context_line":"\t    echo ;                                      \\"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"ba972062_e2ddff7a","line":69,"in_reply_to":"90b1229f_737e9525","updated":"2026-03-10 20:51:49.000000000","message":"Do we want to continue computing diffs against the initial commit even after landing this patch? We can potentially move to `git clang-format --diff HEAD^` but I don\u0027t see that necessary since the codebase is reasonably small:\n```\nwhalbawi@88d0bd4-lcedt:/repos/liberasurecode$ git ls-files -- src include | xargs wc -l | tail -1\n 10543 total\nwhalbawi@88d0bd4-lcedt:/repos/liberasurecode$ time make check-format\nclang-format-18 --version\nUbuntu clang-format version 18.1.3 (1ubuntu1)\ngit clang-format --diff 76a551dc -- src include\ndiff --git a/include/erasurecode/list.h b/include/erasurecode/list.h\nindex 93451ca..c184528 100644\n--- a/include/erasurecode/list.h\n+++ b/include/erasurecode/list.h\n@@ -56,8 +56,7 @@\n     struct type *slh_first; /* first element */                                \\\n   }\n\n-#define SLIST_HEAD_INITIALIZER(head)                                           \\\n-  { NULL }\n+#define SLIST_HEAD_INITIALIZER(head) {NULL}\n\n #define SLIST_ENTRY(type)                                                      \\\n   struct {                                                                     \\\nmake: *** [Makefile:999: check-format] Error 1\n\nreal    0m0.722s\nuser    0m0.401s\nsys     0m0.371s\nwhalbawi@88d0bd4-lcedt:/repos/liberasurecode$\n```","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"d7bb07d17556c7890dcaf92289d0c3540fb7b04d","unresolved":true,"context_lines":[{"line_number":66,"context_line":"\tif ! find src include -type f -name \u0027*.[ch]\u0027 |  \\"},{"line_number":67,"context_line":"\t  grep -v \u0027include/config_liberasurecode\\.h\u0027 |  \\"},{"line_number":68,"context_line":"\t  xargs clang-format-18 -n -Werror ; then       \\"},{"line_number":69,"context_line":"\t    make format ;                               \\"},{"line_number":70,"context_line":"\t    echo ;                                      \\"},{"line_number":71,"context_line":"\t    echo Consider applying the following: ;     \\"},{"line_number":72,"context_line":"\t    echo ;                                      \\"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"14b8a547_9bdbefd3","line":69,"in_reply_to":"f59fe7e5_9d5c384e","updated":"2026-03-10 19:26:47.000000000","message":"TIL!\n\nYeah, I didn\u0027t really *want* to change the tree; looks like `git clang-format --diff` is *exactly* what I want.","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":38767,"name":"Wael Halbawi","display_name":"Wael Halbawi","email":"whalbawi@nvidia.com","username":"whalbawi"},"change_message_id":"905327c986571bbe967b9a1e0d114250ccfb5bc9","unresolved":true,"context_lines":[{"line_number":77,"context_line":"format:"},{"line_number":78,"context_line":"\tclang-format-18 --version"},{"line_number":79,"context_line":"\tfind src include -type f -name \u0027*.[ch]\u0027 |       \\"},{"line_number":80,"context_line":"\t  grep -v \u0027include/config_liberasurecode\\.h\u0027 |  \\"},{"line_number":81,"context_line":"\t  xargs clang-format-18 -i -Werror"},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"CLEANFILES \u003d cscope.in.out cscope.out cscope.po.out"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"8f6d7883_374c750b","line":80,"updated":"2026-03-10 17:49:05.000000000","message":"I believe `git clang-format` respects `.gitignore`.","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"3329a6d5cac1c4d11e7ea8382f8d934234c3ce6a","unresolved":false,"context_lines":[{"line_number":77,"context_line":"format:"},{"line_number":78,"context_line":"\tclang-format-18 --version"},{"line_number":79,"context_line":"\tfind src include -type f -name \u0027*.[ch]\u0027 |       \\"},{"line_number":80,"context_line":"\t  grep -v \u0027include/config_liberasurecode\\.h\u0027 |  \\"},{"line_number":81,"context_line":"\t  xargs clang-format-18 -i -Werror"},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"CLEANFILES \u003d cscope.in.out cscope.out cscope.po.out"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"28a93f5f_454a8f10","line":80,"in_reply_to":"8f6d7883_374c750b","updated":"2026-03-10 20:06:52.000000000","message":"Acknowledged","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"}],"bindep.txt":[{"author":{"_account_id":7233,"name":"Matthew Oliver","email":"matt@oliver.net.au","username":"mattoliverau"},"change_message_id":"8975c6103e754a447b3d12f8dd0a4d3c4f0460b1","unresolved":true,"context_lines":[{"line_number":9,"context_line":"make [platform:rpm]"},{"line_number":10,"context_line":"autoconf"},{"line_number":11,"context_line":"automake"},{"line_number":12,"context_line":"clang-format-18 [platform:dpkg]"},{"line_number":13,"context_line":"libtool"},{"line_number":14,"context_line":"valgrind"}],"source_content_type":"text/plain","patch_set":5,"id":"32699478_7fe87906","line":12,"updated":"2026-03-08 23:18:51.000000000","message":"For fedora/centos/redhat:\n```\nclang18-tools-extra [platform:rpm]\n```","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"a2db5afa35a8d2de4f235eddc23da1cac8968a84","unresolved":true,"context_lines":[{"line_number":9,"context_line":"make [platform:rpm]"},{"line_number":10,"context_line":"autoconf"},{"line_number":11,"context_line":"automake"},{"line_number":12,"context_line":"clang-format-18 [platform:dpkg]"},{"line_number":13,"context_line":"libtool"},{"line_number":14,"context_line":"valgrind"}],"source_content_type":"text/plain","patch_set":5,"id":"68aafaf9_73ff8294","line":12,"in_reply_to":"32699478_7fe87906","updated":"2026-03-10 20:48:01.000000000","message":":-( Looks like I need to get EPEL repos installed then... and ahead of bindep trying to install deps...\n\nI kinda wonder if we should just note the tool in the README or something... ultimately, you could simply wait for the gate to tell you the diff to apply.","commit_id":"5b31f0fa3d3aba3862c346ea5b9d1e43385ce289"}]}
