24 references to IsNullable
Microsoft.CodeAnalysis.CSharp.Features (7)
Completion\Providers\DefaultArgumentProvider.cs (1)
31else if (context.Parameter.Type.IsReferenceType || context.Parameter.Type.IsNullable())
src\Analyzers\CSharp\Analyzers\UseImplicitObjectCreation\CSharpUseImplicitObjectCreationDiagnosticAnalyzer.cs (1)
155if (rightType.IsNullable())
src\Analyzers\CSharp\Analyzers\UsePatternMatching\CSharpAsAndNullCheckDiagnosticAnalyzer.cs (1)
122if (asType.IsNullable())
src\Analyzers\CSharp\Analyzers\UsePatternMatching\CSharpIsAndCastCheckDiagnosticAnalyzer.cs (1)
114if (isType.IsNullable())
src\Analyzers\CSharp\Analyzers\UsePatternMatching\CSharpUseNotPatternDiagnosticAnalyzer.cs (1)
82=> semanticModel.GetTypeInfo(type, cancellationToken).Type.IsNullable()
src\Analyzers\CSharp\CodeFixes\ConvertSwitchStatementToExpression\ConvertSwitchStatementToExpressionCodeFixProvider.Rewriter.cs (1)
110var cannotUseVar = declaratorToRemoveType != null && (declaratorToRemoveType.IsReferenceType || declaratorToRemoveType.IsNullable());
UsePatternMatching\CSharpIsAndCastCheckWithoutNameDiagnosticAnalyzer.cs (1)
128if (typeSymbol == null || typeSymbol.IsNullable())
Microsoft.CodeAnalysis.CSharp.Workspaces (9)
Recommendations\CSharpRecommendationServiceRunner_Conversions.cs (2)
156var containerIsNullable = container.IsNullable(); 240symbols.Add(container.IsNullable() ? LiftConversion(compilation, conversion) : conversion);
Recommendations\CSharpRecommendationServiceRunner_Operators.cs (1)
28var containerIsNullable = container.IsNullable();
Simplification\Simplifiers\NameSimplifier.cs (1)
403if (!type.IsNullable())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeStyle\TypeStyle\TypeStyleHelper.cs (1)
174var returnTypeName = returnType.IsNullable()
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Simplification\Simplifiers\CastSimplifier.cs (1)
334if (isNullLiteralCast && !originalConvertedType.IsReferenceType && !originalConvertedType.IsNullable())
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\ExpressionGenerator.cs (1)
92_ => type == null || type.IsReferenceType || type is IPointerTypeSymbol || type.IsNullable()
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ITypeSymbolExtensions.TypeSyntaxGeneratorVisitor.cs (1)
236if (symbol.IsNullable())
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpSyntaxGeneratorInternal.cs (1)
257type.IsNullable())
Microsoft.CodeAnalysis.Features (3)
InitializeParameter\AbstractAddParameterCheckCodeRefactoringProvider.cs (1)
347else if (!parameter.Type.IsNullable())
src\Analyzers\Core\Analyzers\PopulateSwitch\AbstractPopulateSwitchDiagnosticAnalyzer.cs (1)
105if (type.IsNullable())
src\Analyzers\Core\CodeFixes\AddParameter\AbstractAddParameterCodeFixProvider.cs (1)
547return parameterType.IsReferenceType || parameterType.IsNullable();
Microsoft.CodeAnalysis.Workspaces (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\ITypeSymbolExtensions.cs (3)
37var isNullableValueType = type.IsNullable(); 61=> symbol is { IsValueType: true } && !symbol.IsNullable(); 67if (IsNullable(symbol))
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (1)
205if (namedType.OriginalDefinition.IsSpecialType() || namedType.IsNullable() || namedType.IsTupleType)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\SyntaxGeneratorExtensions.cs (1)
400var shouldAddNullCheck = addNullChecks && parameter.Type.CanAddNullCheck() && !parameter.Type.IsNullable();