https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118629

--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
For
template <int N>
struct S {
  char s[N];
};
const char *z;
auto foo() -> S<sizeof (__func__)> {
  z = __func__;
  return {};
}
int bar() {
  return sizeof (foo ());
}
both gcc and clang warn about it, but I think it shouldn't warn and have sizeof
"foo"
in that case.

Reply via email to