[gnutls-devel] GnuTLS | build: fix comment indentation after applying clang-format (!2123)

(Deprecated) Read-only notification of GnuTLS library development activities gnutls-devel at lists.gnutls.org
Thu Aug 6 11:15:51 CEST 2026



Daiki Ueno created a merge request: https://gitlab.com/gnutls/gnutls/-/merge_requests/2123

Project:Branches: dueno/gnutls:wip/dueno/comments to gnutls/gnutls:master
Author: Daiki Ueno

<!-- Add a description of the new feature/bug fix. Reference any relevant bugs. -->

* build: fix comment indentation after applying clang-format

When applying clang-format back in 2023 in commit aa5950aba, the tool
for some reason indented the first line of multi-line comment block
but not the rest. This fixes it by applying the following Elisp
function with:
```
  cat >indent-comments.el <<EOF
  (defun indent-comments ()
    (goto-char (point-min))
    (while (comment-search-forward nil 'noerror)
      (let ((start (let ((comment-start-skip "")) ; skip "/* "
                     (comment-beginning))))
        (forward-comment 1)
        (indent-region start (point)))))
  EOF

  for i in $(git ls-files | grep '\.c$'); do
    emacs -Q -l indent-comments.el $i -f indent-comments -f save-buffer
  done
```

## Checklist
 * [x] Commits have `Signed-off-by:` with name/author being identical to the commit author
 * [ ] Code modified for feature
 * [ ] Test suite updated with functionality tests
 * [ ] Test suite updated with negative tests
 * [ ] Documentation updated / NEWS entry present (for non-trivial changes)

## Reviewer's checklist:
 * [ ] Any issues marked for closing are addressed
 * [ ] There is a test suite reasonably covering new functionality or modifications
 * [ ] Function naming, parameters, return values, types, etc., are consistent and according to `CONTRIBUTION.md`
 * [ ] This feature/change has adequate documentation added
 * [ ] No obvious mistakes in the code

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/2123
You're receiving this email because of your account on gitlab.com. Unsubscribe from this thread: https://gitlab.com/-/namespace/17175643/sent_notifications/6-cukkb03eucvm0k2u3jk9pd7ye-a84t7/unsubscribe | Manage all notifications: https://gitlab.com/-/profile/notifications | Help: https://gitlab.com/help


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20260806/1c833260/attachment-0001.html>


More information about the Gnutls-devel mailing list