}
return f.newExpressionStatement(f.newFunctionCallExpression(call, initializerClauses.toArray(new IASTInitializerClause[initializerClauses.size()])));
}
private IASTStatement convertEnhancedForStatement(final EnhancedForStatement enhancedForStatement) {
final ICPPASTRangeBasedForStatement rangeBased = f.newRangeBasedForStatement();
final ICPPASTSimpleDeclSpecifier declSpecifier = f.newSimpleDeclSpecifier();
declSpecifier.setStorageClass(IASTDeclSpecifier.sc_auto);
final IASTSimpleDeclaration declaration = f.newSimpleDeclaration(declSpecifier);
final SingleVariableDeclarationInfo parameter = new SingleVariableDeclarationInfo(enhancedForStatement.getParameter(), compilationUnitInfo);
final ICPPASTDeclarator declarator = parameter.getDeclarator();
for (int i = 0; i < declarator.getPointerOperators().length; i++) {
declarator.getPointerOperators()[i] = null;
}
declaration.addDeclarator(declarator);
rangeBased.setDeclaration(declaration);
final ExpressionInfo expressionInfo = new ExpressionInfo(enhancedForStatement.getExpression(), typeDeclaration, compilationUnitInfo);
rangeBased.setInitializerClause(expressionInfo.getExpression());
final StatementInfo body = new StatementInfo(enhancedForStatement.getBody(), typeDeclaration, compilationUnitInfo);
rangeBased.setBody(body.getStatement());
return rangeBased;
}