[llvm] [LAA] refactor program logic (NFC) (PR #92101)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Fri May 24 03:02:32 PDT 2024


fhahn wrote:

> > In the future, it would be good to avoid force pushes and use merge commits instead of rebases to update the PR, as Github deals with merges much better than with force pushes & rebases in terms of retaining comments
> 
> I must admit that I'm a little nervous about using merge commits, since `main` requires linear history, and I'm worried that I might mess something up. Besides, I like to view my branch history locally before submitting, and intervening merge commits make it complicated to do so.

When merging via GitHub, squash-and-merge is the only option, so there should be nothing to worry about in that respect.

Please see https://llvm.org/docs//GitHub.html#rebasing-pull-requests-and-force-pushes for the official recommendation. While a linear history locally might be convenient, preserving the comment and change history as much as possible is also very important for the review process. This is mostly a consequence of how Github PRs work and has been discussed at length before the switch.

https://github.com/llvm/llvm-project/pull/92101


More information about the llvm-commits mailing list