24 references to First
Microsoft.CodeAnalysis.CodeStyle (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ITypeSymbolExtensions.SubstituteTypesVisitor.cs (1)
83symbol = updatedContainingType.GetTypeMembers(symbol.Name, symbol.Arity).First(m => m.TypeKind == symbol.TypeKind);
Microsoft.CodeAnalysis.CSharp (1)
Symbols\Source\SourcePropertySymbolBase.cs (1)
1671=> (SourceAttributeData)GetAttributes().First(a => a.IsTargetAttribute(attributeDescription));
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordEngine.cs (1)
149.First(info => info.Symbol.Equals(symbol)));
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (1)
QuickInfo\SemanticQuickInfoSourceTests.cs (1)
8370item.Sections.First(section => section.Kind == QuickInfoSectionKinds.DocumentationComments).TaggedParts.Select(p => p.Tag).ToArray(),
Microsoft.CodeAnalysis.CSharp.Features (2)
Debugging\BreakpointResolver.cs (1)
35var location = method.Locations.First(loc => loc.IsInSource);
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordEngine.cs (1)
149.First(info => info.Symbol.Equals(symbol)));
Microsoft.CodeAnalysis.CSharp.Features.UnitTests (1)
src\Analyzers\CSharp\Tests\RemoveUnusedMembers\RemoveUnusedMembersTests.cs (1)
1484.Diagnostic(new CSharpRemoveUnusedMembersDiagnosticAnalyzer().SupportedDiagnostics.First(x => x.Id == "IDE0052"))
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (1)
Symbols\ErrorTypeSymbolTests.cs (1)
71var types = new[] { "C1", "C2", "C3", "C4", "C5", "C6", "C7" }.Select(name => allTypes.First(t => t.Name == name).BaseType()).ToArray();
Microsoft.CodeAnalysis.CSharp.Workspaces.UnitTests (2)
CodeGeneration\SymbolEditorTests.cs (2)
1034var property = typeC.GetMembers().First(m => m.Kind == SymbolKind.Property); 1044var iproperty = typeI.GetMembers().First(m => m.Kind == SymbolKind.Property);
Microsoft.CodeAnalysis.Features (3)
Debugging\AbstractBreakpointResolver.cs (1)
80var location = methodSymbol.Locations.First(loc => loc.IsInSource);
ExtractMethod\MethodExtractor.VariableSymbol.cs (2)
171var leftLocation = leftLocations.First(l => l.SourceTree == commonTree); 172var rightLocation = rightLocations.First(l => l.SourceTree == commonTree);
Microsoft.CodeAnalysis.Workspaces (2)
Diagnostics\DocumentAnalysisScope.cs (1)
59return TextDocument.Project.AnalyzerOptions.AdditionalFiles.First(a => PathUtilities.Comparer.Equals(a.Path, filePath));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ITypeSymbolExtensions.SubstituteTypesVisitor.cs (1)
83symbol = updatedContainingType.GetTypeMembers(symbol.Name, symbol.Arity).First(m => m.TypeKind == symbol.TypeKind);
Microsoft.Gen.Metrics.Unit.Tests (2)
EmitterTests.cs (2)
49var result = r.First(x => x.HintName == "Factory.g.cs").SourceText.ToString(); 52result = r.First(x => x.HintName == "Metrics.g.cs").SourceText.ToString();
Microsoft.Interop.ComInterfaceGenerator (2)
Analyzers\ConvertComImportToGeneratedComInterfaceAnalyzer.cs (1)
76AttributeData comImportAttribute = type.GetAttributes().First(attr => attr.AttributeClass.ToDisplayString() == TypeNames.System_Runtime_InteropServices_ComImportAttribute);
Analyzers\ConvertComImportToGeneratedComInterfaceFixer.cs (1)
99var comImportAttribute = await declaringType.GetAttributes().First(attr => attr.AttributeClass.Equals(comImportAttributeType, SymbolEqualityComparer.Default)).ApplicationSyntaxReference.GetSyntaxAsync(ct).ConfigureAwait(false);
Microsoft.Interop.LibraryImportGenerator (2)
Analyzers\ConvertToLibraryImportAnalyzer.cs (1)
142AttributeData dllImportAttribute = method.GetAttributes().First(attr => attr.AttributeClass.ToDisplayString() == TypeNames.DllImportAttribute);
Analyzers\CustomMarshallerAttributeFixer.cs (1)
182=> (ITypeSymbol)attributedTypeSymbol.GetAttributes().First(attr =>
Microsoft.VisualStudio.LanguageServices (2)
ProjectSystem\VisualStudioWorkspaceImpl.OpenFileTracker.cs (1)
287w.OnDocumentContextUpdated(documentIds.First(d => d.ProjectId == activeProjectId));
Venus\ContainedLanguageCodeSupport.cs (1)
210var position = type.Locations.First(loc => loc.SourceTree == targetSyntaxTree).SourceSpan.Start;
System.Text.Json.SourceGeneration (1)
Helpers\RoslynExtensions.cs (1)
87type = namedType = containingType.GetTypeMembers().First(t => t.Name == namedType.Name && t.Arity == namedType.Arity);