Issue 109631
Summary [clang] False Negative: -Wsign-compare not triggered on instantiated templates
Labels clang:diagnostics, false-negative
Assignees
Reporter carlosgalvezp
    Example:

```cpp
#include <cstdint>

template <typename T>
struct Foo
{
    static constexpr T size{123};
};

void f()
{
    std::int32_t foo{123};
    std::uint32_t bar{321U};
    auto x = foo == bar; // OK, -Wsign-compare triggered
    auto y = foo == Foo<std::uint32_t>::size;   // NOK, no warnings
}
```
https://godbolt.org/z/355WMh6hz
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to