47 references to Block
Microsoft.CodeAnalysis.CSharp (14)
Binder\Binder_Statements.cs (1)
3384var block = BindEmbeddedBlock(node.Block, diagnostics);
Binder\LocalBinderFactory.cs (1)
890Visit(node.Block, clauseBinder);
Syntax.xml.Main.Generated.cs (1)
1945=> node.Update(VisitToken(node.CatchKeyword), (CatchDeclarationSyntax?)Visit(node.Declaration), (CatchFilterClauseSyntax?)Visit(node.Filter), (BlockSyntax?)Visit(node.Block) ?? throw new ArgumentNullException("block"));
Syntax.xml.Syntax.Generated.cs (8)
9073if (catchKeyword != this.CatchKeyword || declaration != this.Declaration || filter != this.Filter || block != this.Block) 9083public CatchClauseSyntax WithCatchKeyword(SyntaxToken catchKeyword) => Update(catchKeyword, this.Declaration, this.Filter, this.Block); 9084public CatchClauseSyntax WithDeclaration(CatchDeclarationSyntax? declaration) => Update(this.CatchKeyword, declaration, this.Filter, this.Block); 9085public CatchClauseSyntax WithFilter(CatchFilterClauseSyntax? filter) => Update(this.CatchKeyword, this.Declaration, filter, this.Block); 9088public CatchClauseSyntax AddBlockAttributeLists(params AttributeListSyntax[] items) => WithBlock(this.Block.WithAttributeLists(this.Block.AttributeLists.AddRange(items))); 9089public CatchClauseSyntax AddBlockStatements(params StatementSyntax[] items) => WithBlock(this.Block.WithStatements(this.Block.Statements.AddRange(items)));
Syntax\LookupPosition.cs (3)
296return IsBetweenTokens(position, catchClause.Block.OpenBraceToken, catchClause.Block.CloseBraceToken); 429return lastCatch.Block.CloseBraceToken;
Microsoft.CodeAnalysis.CSharp.CodeStyle (3)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SuppressFormattingRule.cs (3)
242if (!catchClause.CatchKeyword.IsMissing && catchClause.Block != null && !catchClause.Block.CloseBraceToken.IsMissing) 244AddSuppressWrappingIfOnSingleLineOperation(list, catchClause.CatchKeyword, catchClause.Block.CloseBraceToken);
Microsoft.CodeAnalysis.CSharp.EditorFeatures (3)
AutomaticCompletion\AutomaticLineEnderCommandHandler.cs (1)
615CatchClauseSyntax catchClauseNode => catchClauseNode.Block.SpanStart,
AutomaticCompletion\AutomaticLineEnderCommandHandler_Helpers.cs (2)
647&& catchClauseSyntax.Block.OpenBraceToken.IsMissing 648&& !catchClauseSyntax.Block.Span.Contains(caretPosition);
Microsoft.CodeAnalysis.CSharp.Features (8)
Debugging\CSharpProximityExpressionsService.Worker.cs (1)
289AddLastStatementOfConstruct(catchClause.Block);
EditAndContinue\SyntaxComparer.cs (4)
1153var blockDistance = ComputeDistance(left.Block, right.Block); 1155return AdjustForLocalsInBlock(distance, left.Block, right.Block, localsWeight: 0.3);
Structure\Providers\BlockSyntaxStructureProvider.cs (3)
76if (!catchClause.Block.IsMissing) 77subHeadings.Add((GetTextSpan(catchClause.Block), GetHintSpan(catchClause.Block), BlockTypes.Statement));
Microsoft.CodeAnalysis.CSharp.IOperation.UnitTests (1)
IOperation\IOperationTests.cs (1)
668var exceptionBlock = catchBlock.Block;
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (11)
Generated\Syntax.Test.xml.Generated.cs (2)
12904Assert.NotNull(node.Block); 12905var newNode = node.WithCatchKeyword(node.CatchKeyword).WithDeclaration(node.Declaration).WithFilter(node.Filter).WithBlock(node.Block);
Parsing\StatementParsingTests.cs (9)
1247Assert.NotNull(ts.Catches[0].Block); 1276Assert.NotNull(ts.Catches[0].Block); 1300Assert.NotNull(ts.Catches[0].Block); 1331Assert.NotNull(ts.Catches[0].Block); 1339Assert.NotNull(ts.Catches[1].Block); 1343Assert.NotNull(ts.Catches[2].Block); 1397Assert.NotNull(ts.Catches[0].Block); 1405Assert.NotNull(ts.Catches[1].Block); 1409Assert.NotNull(ts.Catches[2].Block);
Microsoft.CodeAnalysis.CSharp.Workspaces (4)
Rename\LocalConflictVisitor.cs (1)
108Visit(node.Block);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SuppressFormattingRule.cs (3)
242if (!catchClause.CatchKeyword.IsMissing && catchClause.Block != null && !catchClause.Block.CloseBraceToken.IsMissing) 244AddSuppressWrappingIfOnSingleLineOperation(list, catchClause.CatchKeyword, catchClause.Block.CloseBraceToken);
Roslyn.Diagnostics.CSharp.Analyzers (3)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SuppressFormattingRule.cs (3)
242if (!catchClause.CatchKeyword.IsMissing && catchClause.Block != null && !catchClause.Block.CloseBraceToken.IsMissing) 244AddSuppressWrappingIfOnSingleLineOperation(list, catchClause.CatchKeyword, catchClause.Block.CloseBraceToken);