aaron.ballman added a reviewer: aaron.ballman.
aaron.ballman added inline comments.


================
Comment at: clang/lib/Parse/ParseTemplate.cpp:876
+/// In C++20:
+///       template-head: [C++ temp.pre]
+///         template '<' template-parameter-list '>' requires-clause[opt]
----------------
Rather than duplicate the grammar for each standard revision, I think we 
usually try to have one grammar section that incorporates all of the changes 
over the years, like how we added `[C++1z]` on line 873 above. Any appetite for 
trying to rearrange like that?


================
Comment at: clang/test/CXX/temp/temp.arg/temp.arg.template/p3-2a.cpp:60-62
+  // A naive individual might expect the following to all fail concept 
checking,
+  // but there does not seem to be any requirement to check these in the
+  // standard, and none of the other implementations do so either.
----------------
I agree that none of the other implementations seems to be checking constraints 
here, but I would have guessed that https://eel.is/c++draft/temp.arg.template#3 
was what would trigger checking the constraints here (the `and for template 
template-parameters, each of their corresponding template-parameters matches, 
recursively.` bit, specifically).

Usually the answer to "Am I misreading the standard or are these three 
implementations all wrong in the same way?" is "I misread the standard.", but 
I'd appreciate some confirmation here. :-)


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

https://reviews.llvm.org/D110641

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

Reply via email to