|
|
|||
File indexing completed on 2026-05-10 08:36:49
0001 //===--- Lambda.h - Types for C++ Lambdas -----------------------*- C++ -*-===// 0002 // 0003 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 0004 // See https://llvm.org/LICENSE.txt for license information. 0005 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 0006 // 0007 //===----------------------------------------------------------------------===// 0008 /// 0009 /// \file 0010 /// Defines several types used to describe C++ lambda expressions 0011 /// that are shared between the parser and AST. 0012 /// 0013 //===----------------------------------------------------------------------===// 0014 0015 0016 #ifndef LLVM_CLANG_BASIC_LAMBDA_H 0017 #define LLVM_CLANG_BASIC_LAMBDA_H 0018 0019 namespace clang { 0020 0021 /// The default, if any, capture method for a lambda expression. 0022 enum LambdaCaptureDefault { 0023 LCD_None, 0024 LCD_ByCopy, 0025 LCD_ByRef 0026 }; 0027 0028 /// The different capture forms in a lambda introducer 0029 /// 0030 /// C++11 allows capture of \c this, or of local variables by copy or 0031 /// by reference. C++1y also allows "init-capture", where the initializer 0032 /// is an expression. 0033 enum LambdaCaptureKind { 0034 LCK_This, ///< Capturing the \c *this object by reference 0035 LCK_StarThis, ///< Capturing the \c *this object by copy 0036 LCK_ByCopy, ///< Capturing by copy (a.k.a., by value) 0037 LCK_ByRef, ///< Capturing by reference 0038 LCK_VLAType ///< Capturing variable-length array type 0039 }; 0040 0041 } // end namespace clang 0042 0043 #endif // LLVM_CLANG_BASIC_LAMBDA_H
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|