[llvm] [EquivClasses] Fix signature of operator= (NFC) (PR #130140)

David Blaikie via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 6 11:17:08 PST 2025


dwblaikie wrote:

> > I'd expect coverage for this in the unit tests?
> 
> The patch is a NFC.

NFC in the sense that it doesn't change the behavior of any LLVM programs, but we generally treat NFC a bit differently when it comes to ADTs or anything that's similarly/more unit testable. In which case we mostly test anything that can be observed on the API surface area. And this can be observed and tested.

Potentially modifying the existing unit test (assuming this function has existing unit test coverage, if not, it should be added) to initialize a non-const ref from the result of the assignment  (& existing test coverage should be checking that resulting reference has the same address as the object)

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


More information about the llvm-commits mailing list