[flang-commits] [flang] [clang-tools-extra] [compiler-rt] [libcxxabi] [openmp] [libcxx] [clang] [mlir] [libc] [llvm] [clang] Avoid -Wshadow warning when init-capture named same as class field (PR #74512)

Nikolas Klauser via flang-commits flang-commits at lists.llvm.org
Mon Dec 11 02:07:41 PST 2023


philnik777 wrote:

I seem to be the only one, but I don't understand how this isn't shadowing. The whole point of the shadowing warning is to avoid confusion about which variable is actually used, which IMO could very well be the case here. I think it would be much better to get a new flag to disable this if it's not wanted than to make it impossible to warn on this shadowing constellation.

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


More information about the flang-commits mailing list