2 writes to Path
Microsoft.CodeAnalysis (2)
Diagnostic\FileLinePositionSpan.cs (2)
63Path = path ?? throw new ArgumentNullException(nameof(path)); 70Path = path;
65 references to Path
GenerateDocumentationAndConfigFiles (1)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\ISolutionExtensions.cs (1)
161var documentId = solution.GetDocumentIdsWithFilePath(location.GetLineSpan().Path).FirstOrDefault();
Microsoft.CodeAnalysis (27)
CodeGen\SequencePointList.cs (3)
123lastPath = firstReal.Value.Path; 168if (lastPath != fileLinePositionSpan.Path || lastPathIsMapped != fileLinePositionSpan.HasMappedPath) 170lastPath = fileLinePositionSpan.Path;
CommandLine\SarifErrorLogger.cs (1)
120return !string.IsNullOrEmpty(location.GetLineSpan().Path);
CommandLine\SarifV1ErrorLogger.cs (1)
143_writer.Write("uri", GetUri(span.Path));
CommandLine\SarifV2ErrorLogger.cs (1)
179_writer.Write("uri", GetUri(span.Path));
Diagnostic\DiagnosticFormatter.cs (3)
47path = mappedSpan.Path; 48basePath = span.Path; 52path = span.Path;
Diagnostic\FileLinePositionSpan.cs (6)
35/// True if the <see cref="Path"/> is a mapped path. 91=> Path != null; // invalid span can be constructed by new FileLinePositionSpan() 102string.Equals(Path, other.Path, StringComparison.Ordinal); 118=> Hash.Combine(Path, Hash.Combine(HasMappedPath, Span.GetHashCode())); 126=> Path + ": " + Span;
Diagnostic\Location.cs (4)
112if (pos.Path != null) 115result += "(" + pos.Path + "@" + (pos.StartLinePosition.Line + 1) + ":" + (pos.StartLinePosition.Character + 1) + ")"; 141if (pos.Path != null) 144result += "(" + pos.Path + "@" + (pos.StartLinePosition.Line + 1) + ":" + (pos.StartLinePosition.Character + 1) + ")";
DiagnosticAnalyzer\AnalysisResultBuilder.cs (1)
311if (_pathToAdditionalTextMap.TryGetValue(externalFileLocation.GetLineSpan().Path, out var additionalTexts))
DiagnosticAnalyzer\AnalysisScope.cs (1)
309!PathUtilities.Comparer.Equals(externalFileLocation.GetLineSpan().Path, filterFile.AdditionalFile.Path))
DiagnosticAnalyzer\AnalyzerExecutor.AnalyzerDiagnosticReporter.cs (1)
139return PathUtilities.Comparer.Equals(_contextFile.Value.AdditionalFile.Path, externalFileLocation.GetLineSpan().Path);
Syntax\LineMapping.cs (1)
29/// If the path is not mapped <see cref="FileLinePositionSpan.Path"/> is empty and <see cref="FileLinePositionSpan.HasMappedPath"/> is false.
Syntax\SyntaxTree.cs (4)
288if (resolver is null || mappedSpan.Path.IsEmpty()) 290return mappedSpan.Path; 293return resolver.NormalizePath(mappedSpan.Path, baseFilePath: mappedSpan.HasMappedPath ? FilePath : null) ?? mappedSpan.Path;
Microsoft.CodeAnalysis.Analyzers (2)
MetaAnalyzers\DiagnosticDescriptorCreationAnalyzer.cs (1)
683properties = properties.Add(DefineDescriptorArgumentCorrectlyFixAdditionalDocumentLocationInfo, $"{span.Start}{AdditionalDocumentLocationInfoSeparator}{span.Length}{AdditionalDocumentLocationInfoSeparator}{fixLocation.GetLineSpan().Path}");
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\ISolutionExtensions.cs (1)
161var documentId = solution.GetDocumentIdsWithFilePath(location.GetLineSpan().Path).FirstOrDefault();
Microsoft.CodeAnalysis.CodeStyle.Fixes (1)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\ISolutionExtensions.cs (1)
161var documentId = solution.GetDocumentIdsWithFilePath(location.GetLineSpan().Path).FirstOrDefault();
Microsoft.CodeAnalysis.CSharp (4)
Compiler\DocumentationCommentCompiler.IncludeElementExpander.cs (1)
483currentXmlFilePath = location.GetLineSpan().Path;
Emitter\Model\PEModuleBuilder.cs (2)
272var debugDocument = DebugDocumentsBuilder.TryGetDebugDocument(span.Path, basePath: null); 464Cci.DebugSourceDocument doc = DebugDocumentsBuilder.TryGetDebugDocument(span.Path, basePath: location.SourceTree.FilePath);
Lowering\Instrumentation\CodeCoverageInstrumenter.cs (1)
483string path = span.Path;
Microsoft.CodeAnalysis.Features (10)
Diagnostics\Service\DocumentAnalysisExecutor_Helpers.cs (1)
167var filePath = location.GetLineSpan().Path;
EditAndContinue\AbstractEditAndContinueAnalyzer.cs (5)
1514if (mappedLineSpan.HasMappedPath && mappedLineSpan.Path != oldStatement.Statement.FileSpan.Path) 2362if (currentSegment.path != oldMappedSpan.Path || currentSegment.delta != lineDelta) 2369if (lastOldStartLine == oldStartLine && string.Equals(lastOldFilePath, oldMappedSpan.Path)) 2386currentSegment = (oldMappedSpan.Path, oldStartLine, lineDelta, oldTokensEnum.Current, newTokensEnum.Current); 2391lastOldFilePath = oldMappedSpan.Path;
EditAndContinue\ActiveStatementsMap.cs (1)
211var targetPath = mappedSection.HasMappedPath ? mappedSection.Path : oldTree.FilePath;
EditAndContinue\EmitSolutionUpdateResults.cs (1)
74fileSpan.Path,
EditAndContinue\SourceFileSpan.cs (1)
77=> new(span.Path, span.Span);
EditAndContinue\Utilities\Extensions.cs (1)
172fileSpan.Path ?? "",
Microsoft.CodeAnalysis.VisualBasic (4)
CommandLine\CommandLineDiagnosticFormatter.vb (1)
137Dim path = diagnostic.Location.GetLineSpan().Path
Compilation\DocumentationComments\DocumentationCommentCompiler.Includes.vb (1)
597currentXmlFilePath = location.GetLineSpan().Path
Emit\PEModuleBuilder.vb (1)
282Dim doc As Cci.DebugSourceDocument = DebugDocumentsBuilder.TryGetDebugDocument(span.Path, basePath:=location.SourceTree.FilePath)
Lowering\Instrumentation\CodeCoverageInstrumenter.vb (1)
440Dim path As String = span.Path
Microsoft.CodeAnalysis.Workspaces (9)
Diagnostics\DiagnosticData.cs (1)
218document = project.Documents.FirstOrDefault(d => d.FilePath == diagnostic.Location.GetLineSpan().Path);
Diagnostics\DiagnosticDataLocation.cs (4)
33/// to <see cref="UnmappedFileSpan"/>. The <see cref="FileLinePositionSpan.Path"/> of this value will be the 62Contract.ThrowIfNull(unmappedFileSpan.Path); 73MappedFileSpan = new FileLinePositionSpan(GetNormalizedFilePath(unmappedFileSpan.Path, mappedSpan.Path), mappedSpan.Span);
Diagnostics\Extensions.cs (1)
459var documentIds = targetTextDocument.Project.Solution.GetDocumentIdsWithFilePath(lineSpan.Path);
Log\WorkspaceStructureLogger.cs (1)
193new XAttribute("path", SanitizePath(diagnostic.Location.GetLineSpan().Path)),
Shared\Extensions\ProjectExtensions.cs (1)
25return project.GetDocumentIdWithFilePath(location.GetLineSpan().Path);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\ISolutionExtensions.cs (1)
161var documentId = solution.GetDocumentIdsWithFilePath(location.GetLineSpan().Path).FirstOrDefault();
Microsoft.Gen.ComplianceReports (3)
Parser.cs (3)
125ci.SourceFilePath = fileLine.Path; 186ci.SourceFilePath = fileLine.Path; 222SourceFilePath = fileLine.Path,
Microsoft.Gen.MetadataExtractor (3)
src\Generators\Microsoft.Gen.ComplianceReports\Parser.cs (3)
125ci.SourceFilePath = fileLine.Path; 186ci.SourceFilePath = fileLine.Path; 222SourceFilePath = fileLine.Path,
Roslyn.Diagnostics.Analyzers (1)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\ISolutionExtensions.cs (1)
161var documentId = solution.GetDocumentIdsWithFilePath(location.GetLineSpan().Path).FirstOrDefault();