[PATCH] D151697: [clang] Add test for CWG1710 and related issues

Vlad Serebrennikov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue May 30 01:52:33 PDT 2023


Endill created this revision.
Endill added reviewers: clang-language-wg, shafik.
Herald added a project: All.
Endill requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.

Those issues focus on `template` keyword being optional in certain type-only contexts (base specifiers, member initializers, typename specifiers), as opposed to be disallowed by the grammar, or required by some implementations. GCC accepts all the tests this patch touches since 10, others fail on various tests: https://godbolt.org/z/1M6KE3W1a

It should be noted that the wording in 1710 <https://cplusplus.github.io/CWG/issues/1710.html> that resolves those issues has been substantially changed by P1787 <https://wg21.link/p1787>. I can't find the post-P1787 wording that covers those issues, but I can't find the intent of changing relevant behavior in P1787 <https://reviews.llvm.org/P1787> either, so I assume that intent of the 1710 resolution is preserved somewhere.

This patch covers the following issues:
CWG314 <https://cplusplus.github.io/CWG/issues/314.html>
CWG343 <https://cplusplus.github.io/CWG/issues/343.html>
CWG1710 <https://cplusplus.github.io/CWG/issues/1710.html>
CWG1794 <https://cplusplus.github.io/CWG/issues/1794.html>
CWG1812 <https://cplusplus.github.io/CWG/issues/1812.html>


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D151697

Files:
  clang/test/CXX/drs/dr17xx.cpp
  clang/test/CXX/drs/dr18xx.cpp
  clang/test/CXX/drs/dr3xx.cpp
  clang/www/cxx_dr_status.html

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D151697.526544.patch
Type: text/x-patch
Size: 6921 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230530/ea897a71/attachment.bin>


More information about the cfe-commits mailing list