2 writes to _semanticDocument
Microsoft.CodeAnalysis.Features (2)
GenerateType\AbstractGenerateTypeService.Editor.cs (2)
54_semanticDocument = document; 73_semanticDocument = document;
48 references to _semanticDocument
Microsoft.CodeAnalysis.Features (48)
GenerateType\AbstractGenerateTypeService.Editor.cs (30)
108_semanticDocument.Project, 109_semanticDocument.Project, 129if (_semanticDocument.Project.Language != _generateTypeOptionsResult.Project.Language) 149_semanticDocument.Project, 156_semanticDocument.Project, 166var rootNamespace = _service.GetRootNamespace(_semanticDocument.SemanticModel.Compilation.Options).Trim(); 197if (_semanticDocument.Project.Language == LanguageNames.VisualBasic) 310: [.. _semanticDocument.Document.Folders]; 312if (newDocument.Project.Language == _semanticDocument.Document.Project.Language) 318codeGenResult = await formattingService.FormatNewDocumentAsync(codeGenResult, _semanticDocument.Document, cleanupOptions, _cancellationToken).ConfigureAwait(false); 363updatedSolution, modifiedRoot: null, _semanticDocument.Document, _state.SimpleName, 388var enclosingNamespace = _semanticDocument.SemanticModel.GetEnclosingNamespace( 391var solution = _semanticDocument.Project.Solution; 395new CodeGenerationContext(afterThisLocation: _semanticDocument.SyntaxTree.GetLocation(_state.SimpleName.Span))), 437var solution = _semanticDocument.Project.Solution; 453generateTypeOptionsResult.ExistingDocument.Id == _semanticDocument.Document.Id ? newRoot : null, 454_semanticDocument.Document, 506if ((_semanticDocument.Project == _generateTypeOptionsResult.Project && _semanticDocument.Project.Language == LanguageNames.CSharp) || 526if ((_semanticDocument.Project == _generateTypeOptionsResult.Project && _semanticDocument.Project.Language == LanguageNames.VisualBasic) || 527(_semanticDocument.Project != _generateTypeOptionsResult.Project && _targetProjectChangeInLanguage == TargetProjectChangeInLanguage.NoChange && _generateTypeOptionsResult.Project.Language == LanguageNames.VisualBasic) || 550var solution = _semanticDocument.Project.Solution; 565var types = argumentList.Select(a => _service.DetermineArgumentType(_semanticDocument.SemanticModel, a, _cancellationToken)); 571var syntaxFacts = _semanticDocument.Document.GetRequiredLanguageService<ISyntaxFactsService>(); 578var compilation = _semanticDocument.SemanticModel.Compilation; 609var fieldNamingRule = await _semanticDocument.Document.GetApplicableNamingRuleAsync(SymbolKind.Field, Accessibility.Private, _cancellationToken).ConfigureAwait(false); 625_service.IsConversionImplicit(_semanticDocument.SemanticModel.Compilation, parameterType, field.Type); 633_service.IsConversionImplicit(_semanticDocument.SemanticModel.Compilation, parameterType, property.Type); 655return _semanticDocument.SemanticModel.Compilation.Assembly.IsSameAssemblyOrHasFriendAccessTo(
GenerateType\AbstractGenerateTypeService.GenerateNamedType.cs (18)
149var syntaxFacts = _semanticDocument.Document.GetLanguageService<ISyntaxFactsService>(); 156c => GenerateConstructorHelpers.CanDelegateTo(_semanticDocument, parameters, expressions, c)); 162var factory = _semanticDocument.Document.GetLanguageService<SyntaxGenerator>(); 175var typeInference = _semanticDocument.Document.GetLanguageService<ITypeInferenceService>(); 178if (_service.TryGenerateProperty(property, _semanticDocument.SemanticModel, typeInference, _cancellationToken, out var generatedProperty)) 188var factory = _semanticDocument.Document.GetLanguageService<SyntaxGenerator>(); 190var availableTypeParameters = _service.GetAvailableTypeParameters(_state, _semanticDocument.SemanticModel, _intoNamespace, _cancellationToken); 192var parameterNames = _service.GenerateParameterNames(_semanticDocument.SemanticModel, argumentList, _cancellationToken); 198var syntaxFacts = _semanticDocument.Document.GetLanguageService<ISyntaxFactsService>(); 206_semanticDocument.SemanticModel.Compilation, availableTypeParameters); 223_semanticDocument.SemanticModel, 236var factory = _semanticDocument.Document.GetLanguageService<SyntaxGenerator>(); 237var exceptionType = _semanticDocument.SemanticModel.Compilation.ExceptionType(); 258var serializableType = _semanticDocument.SemanticModel.Compilation.SerializableAttributeType(); 270=> _service.GetAccessibility(_state, _semanticDocument.SemanticModel, _intoNamespace, _cancellationToken); 302_semanticDocument.SemanticModel.Compilation, GetAvailableTypeParameters()) as INamedTypeSymbol; 309=> _service.GetTypeParameters(_state, _semanticDocument.SemanticModel, _cancellationToken); 322var availableInnerTypeParameters = _service.GetTypeParameters(_state, _semanticDocument.SemanticModel, _cancellationToken);