smeenai added a comment.

Similar to the case @mstorsjo mentioned, this also causes the following code to 
fail now:

  struct S {
      unsigned size;
  };
  
  template <class T>
  struct U {
      S s;
      unsigned size() { return s.size(); }
  };

This is obviously invalid, and I personally prefer getting the error early 
instead of having to wait for the instantiation, but it is different from gcc 
and MSVC: https://godbolt.org/z/yoDDjS. I think the earlier diagnosis should be 
okay from a conformance point of view though (but I'm far from being 
well-versed with that).


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D69950/new/

https://reviews.llvm.org/D69950



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to