/// \brief Create a field within the lambda class for the variable
/// being captured.
-// FIXME: Delete VarDecl *Var below, it is not used in the function.
-static void addAsFieldToClosureType(Sema &S, LambdaScopeInfo *LSI, VarDecl *Var,
+static void addAsFieldToClosureType(Sema &S, LambdaScopeInfo *LSI,
QualType FieldType, QualType DeclRefType,
SourceLocation Loc,
bool RefersToCapturedVariable) {
// Capture this variable in the lambda.
if (BuildAndDiagnose)
- addAsFieldToClosureType(S, LSI, Var, CaptureType, DeclRefType, Loc,
+ addAsFieldToClosureType(S, LSI, CaptureType, DeclRefType, Loc,
RefersToCapturedVariable);
// Compute the type of a reference to this captured variable.