aaronpuchert added a comment.

Let's have a look at an example. Do we allow this?

  template<typename T, int... args>
  int x = [](T = T()){ return 0; }(args...);
  
  template int x<int>; // Uses default argument int() = 0.
  
  struct S { S(int); };
  template int x<S, 0>; // Default argument not well-formed, but not needed.

Currently we don't, and neither does GCC.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D76038



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

Reply via email to