aaron.ballman added a reviewer: aaron.ballman.
aaron.ballman added inline comments.
Herald added a project: clang.


================
Comment at: test/SemaCXX/cxx1z-class-template-argument-deduction.cpp:360-361
+  struct Type {
+    Typo(); // expected-error{{deduction guide must be declared in the same 
scope}}
+    // expected-error@-1{{deduction guide declaration without trailing return 
type}}
+  };
----------------
These errors are pretty unfortunate -- they don't really help the user to 
understand what's gone wrong here. They're an improvement over the crash, but I 
think we should try to make the errors more useful if we can.

Why is `Typo()` being treated as a deduction guide? Perhaps we could look to 
see if there is a `->` before making that determination?


Repository:
  rC Clang

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

https://reviews.llvm.org/D57540



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

Reply via email to