-Wunused-const-variable
incorrectly warns for exported lambda
#85122
Labels
clang:diagnostics
New/improved warning or error message in Clang, but not in clang-tidy or static analyzer
clang:modules
C++20 modules and Clang Header Modules
false-positive
Warning fires when it should not
lambda
C++11 lambda expressions
Compiling the following translation unit with
-Wunused-const-variable
:causes clang to report
See it live: https://godbolt.org/z/555Y3q9fe
Anything exported from a module should never be considered unused.
The text was updated successfully, but these errors were encountered: