[PATCH] D16163: [Concepts] Diagnose when return type of a function concept or declaration type of a variable concept is not bool.

Nathan Wilson via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 13 16:08:11 PST 2016


nwilson created this revision.
nwilson added reviewers: rsmith, faisalv, hubert.reinterpretcast, aaron.ballman.
nwilson added a subscriber: cfe-commits.

Adding checks and diagnostics which fall under Concepts TS[dcl.spec.concept]p5:
function concepts are required to have 'bool' return type. 
Adding checks and  diagnostics which fall under Concepts TS[dcl.spec.concept]p6:
variable concepts are required to have 'bool' declaration type.

Remove a test in Parser which caused a regression due to the new checks.

http://reviews.llvm.org/D16163

Files:
  include/clang/Basic/DiagnosticSemaKinds.td
  lib/Sema/SemaDecl.cpp
  test/CXX/concepts-ts/dcl.dcl/dcl.spec/dcl.spec.concept/p5.cpp
  test/CXX/concepts-ts/dcl.dcl/dcl.spec/dcl.spec.concept/p6.cpp
  test/Parser/cxx-concept-declaration.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D16163.44811.patch
Type: text/x-patch
Size: 4742 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160114/074eb595/attachment.bin>


More information about the cfe-commits mailing list