[PATCH] Generic Lambdas: A first step

Faisal Vali faisalv at yahoo.com
Sat Aug 17 11:54:25 PDT 2013


  - incorporates jdennet's suggestions regarding improving comments
  - made some slight modifications to ActOnCapScopeReturnStmt so that during return type deduction of lambdas, in C++1y, the 'auto' path is used to deduce (this modifies rsmith's recent fix - hope this is ok for now - i think eventually this will need to be reworked carefully to avoid reptetitive code - but hopefully this can wait).  In addition the error for having no trailing return type, vs having an explicit 'auto' as return type is made distinct.

  Unless anyone has any major concerns with the direction of this patch - i'd like to commit it by mid to end of next week, so i can start working on capturing and nested lambdas (before i lose too much momentum).  Our friends at GCC are also in the process of completing implementation of this feature (http://gcc.gnu.org/ml/gcc-patches/2013-08/msg00632.html) and it would be nice to join them in offering support for more of C++14 :)
  Thanks!

Hi rsmith, doug.gregor, eli.friedman,

http://llvm-reviews.chandlerc.com/D1174

CHANGE SINCE LAST DIFF
  http://llvm-reviews.chandlerc.com/D1174?vs=2881&id=3548#toc

Files:
  include/clang/AST/ASTContext.h
  include/clang/AST/DeclCXX.h
  include/clang/AST/ExprCXX.h
  include/clang/AST/Type.h
  include/clang/Basic/DiagnosticSemaKinds.td
  include/clang/Sema/DeclSpec.h
  include/clang/Sema/ScopeInfo.h
  include/clang/Sema/Sema.h
  include/clang/Sema/SemaLambda.h
  lib/AST/ASTContext.cpp
  lib/AST/ASTImporter.cpp
  lib/AST/DeclCXX.cpp
  lib/AST/ExprCXX.cpp
  lib/AST/Type.cpp
  lib/CodeGen/CodeGenFunction.cpp
  lib/Parse/ParseAST.cpp
  lib/Parse/ParseDecl.cpp
  lib/Parse/ParseExprCXX.cpp
  lib/Parse/Parser.cpp
  lib/Sema/Sema.cpp
  lib/Sema/SemaDecl.cpp
  lib/Sema/SemaDeclCXX.cpp
  lib/Sema/SemaLambda.cpp
  lib/Sema/SemaOverload.cpp
  lib/Sema/SemaStmt.cpp
  lib/Sema/SemaTemplateDeduction.cpp
  lib/Sema/SemaTemplateInstantiateDecl.cpp
  lib/Sema/SemaType.cpp
  lib/Sema/TreeTransform.h
  lib/Serialization/ASTReader.cpp
  lib/Serialization/ASTReaderDecl.cpp
  lib/Serialization/ASTWriter.cpp
  test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p3-generic-lambda-1y.cpp
  test/CXX/expr/expr.prim/expr.prim.lambda/generic-lambda-unimplemented-1y.cpp
  test/CXX/expr/expr.prim/expr.prim.lambda/p2-generic-lambda-1y.cpp
  test/CXX/expr/expr.prim/expr.prim.lambda/p4-1y.cpp
  test/CXX/expr/expr.prim/expr.prim.lambda/p4.cpp
  test/CXX/expr/expr.prim/expr.prim.lambda/p5-generic-lambda-1y.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D1174.2.patch
Type: text/x-patch
Size: 82723 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130817/2b834a58/attachment.bin>


More information about the cfe-commits mailing list