31 references to ElasticAnnotation
Microsoft.CodeAnalysis.CodeStyle (4)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SyntaxTriviaExtensions.cs (2)
16=> trivia.HasAnnotation(SyntaxAnnotation.ElasticAnnotation); 19=> trivia.WithAdditionalAnnotations(SyntaxAnnotation.ElasticAnnotation);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Formatting\FormattingExtensions.cs (2)
270if (annotation == SyntaxAnnotation.ElasticAnnotation) 272var tokens = node.GetAnnotatedTrivia(SyntaxAnnotation.ElasticAnnotation).Select(tr => tr.Token).Distinct();
Microsoft.CodeAnalysis.CSharp (2)
Syntax\InternalSyntax\SyntaxFactory.cs (2)
77return trivia.WithAnnotationsGreen(new[] { SyntaxAnnotation.ElasticAnnotation }); 88return trivia.WithAnnotationsGreen(new[] { SyntaxAnnotation.ElasticAnnotation });
Microsoft.CodeAnalysis.CSharp.CodeStyle (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\ElasticTriviaFormattingRule.cs (1)
45basePropertyDeclaration.GetAnnotatedTrivia(SyntaxAnnotation.ElasticAnnotation).Any())
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
src\Analyzers\CSharp\CodeFixes\UseImplicitOrExplicitType\UseExplicitTypeCodeFixProvider.cs (1)
96.Concat(variableDesignation.GetAllPrecedingTriviaToPreviousToken().Where(t => !t.IsWhitespace()).Select(t => t.WithoutAnnotations(SyntaxAnnotation.ElasticAnnotation)));
Microsoft.CodeAnalysis.CSharp.Features (1)
src\Analyzers\CSharp\CodeFixes\UseImplicitOrExplicitType\UseExplicitTypeCodeFixProvider.cs (1)
96.Concat(variableDesignation.GetAllPrecedingTriviaToPreviousToken().Where(t => !t.IsWhitespace()).Select(t => t.WithoutAnnotations(SyntaxAnnotation.ElasticAnnotation)));
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\ElasticTriviaFormattingRule.cs (1)
45basePropertyDeclaration.GetAnnotatedTrivia(SyntaxAnnotation.ElasticAnnotation).Any())
Microsoft.CodeAnalysis.CSharp.Workspaces.UnitTests (7)
CodeGeneration\AddAttributesTests.cs (1)
60var formatted = await Formatter.FormatAsync(changedDoc, SyntaxAnnotation.ElasticAnnotation, CSharpSyntaxFormattingOptions.Default, CancellationToken.None);
CodeGeneration\AddImportsTests.cs (2)
95var formatted = await Formatter.FormatAsync(imported, SyntaxAnnotation.ElasticAnnotation, formattingOptions, CancellationToken.None); 103var formatted = await Formatter.FormatAsync(reduced, SyntaxAnnotation.ElasticAnnotation, formattingOptions, CancellationToken.None);
CodeGeneration\SymbolEditorTests.cs (1)
58document = await Formatter.FormatAsync(document, SyntaxAnnotation.ElasticAnnotation, CSharpSyntaxFormattingOptions.Default, CancellationToken.None);
CodeGeneration\SyntaxGeneratorTests.cs (1)
4585var elasticOnlyFormatted = Formatter.Format(newRoot, SyntaxAnnotation.ElasticAnnotation, _workspace.Services.SolutionServices, CSharpSyntaxFormattingOptions.Default, CancellationToken.None).ToFullString();
Formatting\FormattingElasticTriviaTests.cs (1)
132var elasticOnlyFormatted = Formatter.Format(newRoot, SyntaxAnnotation.ElasticAnnotation, workspace.Services.SolutionServices, options, CancellationToken.None).ToFullString();
Formatting\FormattingTriviaTests.cs (1)
1789.WithAdditionalAnnotations(SyntaxAnnotation.ElasticAnnotation));
Microsoft.CodeAnalysis.Features (4)
ChangeSignature\AbstractChangeSignatureService.cs (1)
426var formattedDoc = await Formatter.FormatAsync(reducedDoc, SyntaxAnnotation.ElasticAnnotation, cleanupOptions.FormattingOptions, cancellationToken).ConfigureAwait(false);
MoveToNamespace\AbstractMoveToNamespaceService.cs (1)
279var formattedDocument = await Formatter.FormatAsync(document, SyntaxAnnotation.ElasticAnnotation, formattingOptions, cancellationToken).ConfigureAwait(false);
Snippets\SnippetProviders\AbstractSnippetProvider.cs (2)
132(oldToken, _) => oldToken.WithAdditionalAnnotations(SyntaxAnnotation.ElasticAnnotation) 157document = await Formatter.FormatAsync(document, SyntaxAnnotation.ElasticAnnotation, syntaxFormattingOptions, cancellationToken: cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.VisualBasic (2)
Syntax\InternalSyntax\SyntaxFactory.vb (2)
50Return trivia.WithAnnotations(SyntaxAnnotation.ElasticAnnotation) 59Return trivia.WithAnnotations(SyntaxAnnotation.ElasticAnnotation)
Microsoft.CodeAnalysis.VisualBasic.Workspaces.UnitTests (2)
CodeGeneration\AddImportsTests.vb (2)
101Dim formatted = Await Formatter.FormatAsync(imported, SyntaxAnnotation.ElasticAnnotation, formattingOptions, CancellationToken.None) 108Dim formatted = Await Formatter.FormatAsync(reduced, SyntaxAnnotation.ElasticAnnotation, formattingOptions, CancellationToken.None)
Microsoft.CodeAnalysis.Workspaces (5)
CodeActions\CodeAction_Cleanup.cs (1)
55var document2 = await Formatter.FormatAsync(document1, SyntaxAnnotation.ElasticAnnotation, options.FormattingOptions, cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SyntaxTriviaExtensions.cs (2)
16=> trivia.HasAnnotation(SyntaxAnnotation.ElasticAnnotation); 19=> trivia.WithAdditionalAnnotations(SyntaxAnnotation.ElasticAnnotation);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Formatting\FormattingExtensions.cs (2)
270if (annotation == SyntaxAnnotation.ElasticAnnotation) 272var tokens = node.GetAnnotatedTrivia(SyntaxAnnotation.ElasticAnnotation).Select(tr => tr.Token).Distinct();
Microsoft.CodeAnalysis.Workspaces.UnitTests (1)
SolutionTests\SolutionTests.cs (1)
3693var newRoot = doc.GetSyntaxRootAsync().Result.WithAdditionalAnnotations(SyntaxAnnotation.ElasticAnnotation);