[clang] [clang-tools-extra] [Clang] Default the warning for chained comparison to an error. (PR #128145)

Erich Keane via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 24 07:20:01 PST 2025


erichkeane wrote:

> Hello, We are maintaining a downstream version of the monorepo based on the LLVM main branch. We have encountered validation failures with our language conformance test suites when merging in this upstream commit into our monorepo. We are seeing below errors: error: comparisons like 'X<=Y<=Z' don't have their mathematical meaning [-Wparentheses]

Can you provide code examples that you think improperly hits this warning?  We expect this to diagnose on existing code (that is, afterall, the purpose of adding warnings!), so unless there is code you think this is mistakenly diagnosing, that is likely intended.

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


More information about the cfe-commits mailing list