21 references to CreateBlock
Microsoft.CodeAnalysis.CSharp.Workspaces (21)
CodeGeneration\CSharpSyntaxGenerator.cs (21)
246body: hasBody ? CreateBlock(statements) : null, 268var body = hasBody ? CreateBlock(statements) : null; 372CreateBlock(statements)); 440: accessor.WithBody(CreateBlock(statements)); 527statements != null ? CreateBlock(statements) : null); 658return method is { Body: null, ExpressionBody: null } ? method.WithSemicolonToken(default).WithBody(CreateBlock()) : method; 681? accessor.WithSemicolonToken(default).WithBody(CreateBlock(null)) 2474return ((ParenthesizedLambdaExpressionSyntax)declaration).WithBody((CSharpSyntaxNode)expr ?? CreateBlock()); 2477return ((SimpleLambdaExpressionSyntax)declaration).WithBody((CSharpSyntaxNode)expr ?? CreateBlock()); 2653var body = CreateBlock(statements, existingBlock, addSimplifierAnnotation: false); 3253CreateBlock(trueStatements)); 3262CreateBlock(trueStatements), 3264falseArray is [IfStatementSyntax ifStatement] ? ifStatement : CreateBlock(falseArray))); 3558statement: CreateBlock(statements)); 3566statement: CreateBlock(statements)); 3573statement: CreateBlock(statements)); 3579CreateBlock(tryStatements), 3581finallyStatements != null ? SyntaxFactory.FinallyClause(CreateBlock(finallyStatements)) : null); 3589block: CreateBlock(statements)); 3593=> SyntaxFactory.WhileStatement((ExpressionSyntax)condition, CreateBlock(statements)); 3666=> this.ValueReturningLambdaExpression(parameterDeclarations, CreateBlock(statements));