tstellar wrote:
I'm seeing a regression from this commit too with this reproducer which gcc
accepts. Is clang correct to give an error here?
```
template <class _Tp> using decay_t = _Tp;
namespace base::internal {
template <typename Enum> struct EnumSizeTraits {
static constexpr Enum Count() { return Enum(Enum::kMaxValue + 1); }
};
} // namespace base::internal
enum { kUnknown = 3, kMaxValue = kUnknown };
void SandboxLinuxReportLandlockStatus() {
static_assert(
base::internal::EnumSizeTraits<decay_t<decltype(kUnknown)>>::Count());
}
```
https://github.com/llvm/llvm-project/pull/143034
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits