3 overrides of GetLineSpan
Microsoft.CodeAnalysis (3)
Diagnostic\ExternalFileLocation.cs (1)
41public override FileLinePositionSpan GetLineSpan()
Diagnostic\SourceLocation.cs (1)
80public override FileLinePositionSpan GetLineSpan()
Diagnostic\XmlLocation.cs (1)
56public override FileLinePositionSpan GetLineSpan()
75 references to GetLineSpan
ConfigurationSchemaGenerator (1)
RuntimeSource\SourceGenerators\DiagnosticInfo.cs (1)
34=> Location.Create(location.SourceTree?.FilePath ?? "", location.SourceSpan, location.GetLineSpan().Span);
ILLink.RoslynAnalyzer (8)
DataFlow\LocalDataFlowVisitor.cs (7)
104 $"{OwningSymbol.GetType ()}: {branchValueOperation.Syntax.GetLocation ().GetLineSpan ()}"); 112 $"{OwningSymbol.GetType ()}: {branchValueOperation.Syntax.GetLocation ().GetLineSpan ()}"); 205 $"{local.ContainingSymbol.GetType ()}: {localReference.Syntax.GetLocation ().GetLineSpan ()}"); 452 $"{operation.Syntax.GetLocation ().GetLineSpan ()}"); 454 $"{operation.Syntax.GetLocation ().GetLineSpan ()}"); 473 $"{operation.Syntax.GetLocation ().GetLineSpan ()}"); 475 $"{operation.Syntax.GetLocation ().GetLineSpan ()}");
DataFlow\UnexpectedOperationHandler.cs (1)
47 throw new NotImplementedException ($"Unexpected operation type {operation.GetType ()}: {operation.Syntax.GetLocation ().GetLineSpan ()}");
Microsoft.Analyzers.Local.Tests (1)
InternalReferencedInPublicDocAnalyzerTests.cs (1)
469Assert.Equal(lineNumbers[i], location.GetLineSpan().StartLinePosition.Line);
Microsoft.AspNetCore.Analyzer.Testing (1)
Assert.cs (1)
13var actualSpan = actual.GetLineSpan();
Microsoft.AspNetCore.Components.Analyzers.Tests (2)
Verifiers\DiagnosticVerifier.cs (2)
192var actualSpan = actual.GetLineSpan(); 262var linePosition = diagnostics[i].Location.GetLineSpan().StartLinePosition;
Microsoft.AspNetCore.Components.SdkAnalyzers.Tests (2)
Verifiers\DiagnosticVerifier.cs (2)
192var actualSpan = actual.GetLineSpan(); 262var linePosition = diagnostics[i].Location.GetLineSpan().StartLinePosition;
Microsoft.CodeAnalysis (5)
CommandLine\SarifErrorLogger.cs (1)
120return !string.IsNullOrEmpty(location.GetLineSpan().Path);
Diagnostic\DiagnosticFormatter.cs (1)
37var span = diagnostic.Location.GetLineSpan();
Diagnostic\Location.cs (2)
111var pos = GetLineSpan(); 140var pos = GetLineSpan();
DiagnosticAnalyzer\SymbolDeclaredCompilationEvent.cs (1)
53var loc = DeclaringSyntaxReferences.Length != 0 ? " @ " + string.Join(", ", System.Linq.Enumerable.Select(DeclaringSyntaxReferences, r => r.GetLocation().GetLineSpan())) : null;
Microsoft.CodeAnalysis.CSharp (3)
Compiler\DocumentationCommentCompiler.IncludeElementExpander.cs (1)
483currentXmlFilePath = location.GetLineSpan().Path;
Emitter\Model\PEModuleBuilder.cs (1)
452FileLinePositionSpan span = location.GetLineSpan();
Symbols\Source\SourceMethodSymbolWithAttributes.cs (1)
1314var linePositionZeroBased = referencedToken.GetLocation().GetLineSpan().StartLinePosition;
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (1)
Diagnostics\DiagnosticAnalyzerTests.cs (1)
3906Assert.Equal(additionalFile.Path, location.GetLineSpan().Path);
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (12)
Diagnostics\LocationsTests.cs (12)
94FileLinePositionSpan flpsX = locX.GetLineSpan(); 108FileLinePositionSpan flpsXToCloseBrace = locXToCloseBrace.GetLineSpan(); 314FileLinePositionSpan flps = diag.Location.GetLineSpan(); 332flps = diag.Location.GetLineSpan(); 352flps = diag.Location.GetLineSpan(); 377FileLinePositionSpan flps = diag.Location.GetLineSpan(); 418var span = syntaxTree.GetDiagnostics().ElementAt(3).Location.GetLineSpan(); 460expressionDiags.First().Location.GetLineSpan(); 529var lineInfo = locationWithoutMapping.GetLineSpan(); 539lineInfo = locationWithMapping.GetLineSpan(); 572var lineSpan = diagnostics[0].Location.GetLineSpan(); 600var lineSpan = diagnostics[0].Location.GetLineSpan();
Microsoft.CodeAnalysis.Features (2)
CodeLens\CodeLensReferencesService.cs (1)
147var startLinePosition = location.GetLineSpan().StartLinePosition;
ExternalAccess\VSTypeScript\VSTypeScriptTaskListService.cs (1)
42var span = location.GetLineSpan();
Microsoft.CodeAnalysis.LanguageServer.Protocol (2)
Features\Diagnostics\DocumentAnalysisExecutor_Helpers.cs (2)
362var filePath = location.GetLineSpan().Path; 428var lineSpan = diagnostic.Location.GetLineSpan();
Microsoft.CodeAnalysis.Test.Utilities (4)
Diagnostics\CommonDiagnosticAnalyzers.cs (4)
107var expectedLineSpan = root.GetLocation().GetLineSpan(); 185var expectedLineSpan = root.GetLocation().GetLineSpan(); 262var expectedLineSpan = root.GetLocation().GetLineSpan(); 315var expectedLineSpan = root.GetLocation().GetLineSpan();
Microsoft.CodeAnalysis.VisualBasic (3)
CommandLine\CommandLineDiagnosticFormatter.vb (1)
137Dim path = diagnostic.Location.GetLineSpan().Path
Compilation\DocumentationComments\DocumentationCommentCompiler.Includes.vb (1)
597currentXmlFilePath = location.GetLineSpan().Path
Emit\PEModuleBuilder.vb (1)
280Dim span As FileLinePositionSpan = location.GetLineSpan()
Microsoft.CodeAnalysis.VisualBasic.Features (4)
CodeFixes\MoveToTopOfFile\MoveToTopOfFileCodeFixProvider.MoveToLineCodeAction.vb (1)
36Dim lineToMove = _token.GetLocation().GetLineSpan().StartLinePosition.Line
CodeFixes\MoveToTopOfFile\MoveToTopOfFileCodeFixProvider.vb (3)
105destinationLine = root.Options.Last().GetLocation().GetLineSpan().EndLinePosition.Line + 1 143destinationLine = root.Imports.Last().GetLocation().GetLineSpan().EndLinePosition.Line + 1 145destinationLine = root.Options.Last().GetLocation().GetLineSpan().EndLinePosition.Line + 1
Microsoft.CodeAnalysis.VisualBasic.Symbol.UnitTests (5)
SymbolsTests\Source\TypeTests.vb (5)
461Dim span = DirectCast(sym21.Locations(0), Location).GetLineSpan() 497span = DirectCast(sym61.Locations(0), Location).GetLineSpan() 511span = DirectCast(sym71.Locations(0), Location).GetLineSpan() 518span = DirectCast(sym72.Locations(0), Location).GetLineSpan() 525span = DirectCast(sym73.Locations(0), Location).GetLineSpan()
Microsoft.CodeAnalysis.Workspaces (4)
CodeFixes\CodeFix.cs (1)
72var document = Project.Documents.FirstOrDefault(d => d.FilePath == diagnostic.Location.GetLineSpan().Path);
Diagnostics\DiagnosticData.cs (1)
183originalLineInfo = location.GetLineSpan();
Shared\Extensions\ISolutionExtensions.cs (1)
49var documentId = solution.GetDocumentIdsWithFilePath(location.GetLineSpan().Path).FirstOrDefault();
Shared\Extensions\ProjectExtensions.cs (1)
25return project.GetDocumentIdWithFilePath(location.GetLineSpan().Path);
Microsoft.CodeAnalysis.Workspaces.UnitTests (1)
FindReferencesTests.cs (1)
644var line = location.GetLineSpan().StartLinePosition.Line;
Microsoft.Gen.ComplianceReports (3)
Parser.cs (3)
124FileLinePositionSpan fileLine = ps.Locations[0].GetLineSpan(); 185FileLinePositionSpan fileLine = member.Locations[0].GetLineSpan(); 219FileLinePositionSpan fileLine = p.Locations[0].GetLineSpan();
Microsoft.VisualStudio.LanguageServices (9)
CallHierarchy\CallHierarchyDetail.cs (5)
33EndColumn = location.GetLineSpan().Span.End.Character; 34EndLine = location.GetLineSpan().EndLinePosition.Line; 36StartColumn = location.GetLineSpan().StartLinePosition.Character; 37StartLine = location.GetLineSpan().StartLinePosition.Line; 43var lineSpan = location.GetLineSpan();
Diagnostics\VisualStudioVenusSpanMappingService.cs (2)
34originalLineInfo = location.GetLineSpan(); 79var filePath = location.GetLineSpan().Path;
Progression\GraphBuilder.cs (1)
234var lineSpan = preferredLocation.GetLineSpan();
Progression\GraphQueries\IsUsedByGraphQuery.cs (1)
52var span = location.GetLineSpan();
System.Text.Json.SourceGeneration (1)
src\libraries\Common\src\SourceGenerators\DiagnosticInfo.cs (1)
34=> Location.Create(location.SourceTree?.FilePath ?? "", location.SourceSpan, location.GetLineSpan().Span);
System.Text.RegularExpressions.Generator (1)
RegexGenerator.Parser.cs (1)
255return Location.Create(location.SourceTree?.FilePath ?? string.Empty, location.SourceSpan, location.GetLineSpan().Span);