43 references to FunctionPointer
Microsoft.CodeAnalysis (1)
MetadataReader\MetadataDecoder.cs (1)
1022value = (type.IsReferenceType || type.TypeKind == TypeKind.Pointer || type.TypeKind == TypeKind.FunctionPointer) ? ConstantValue.Null : ConstantValue.Bad;
Microsoft.CodeAnalysis.CodeStyle (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ITypeSymbolExtensions.cs (1)
91=> symbol?.TypeKind == TypeKind.FunctionPointer;
Microsoft.CodeAnalysis.CSharp (27)
Binder\Binder_Constraints.cs (1)
618case TypeKind.FunctionPointer:
Binder\Binder_Crefs.cs (1)
560case TypeKind.FunctionPointer:
Binder\Binder_Expressions.cs (2)
2831TypeKind.FunctionPointer => ErrorCode.ERR_MethFuncPtrMismatch, 5173case TypeKind.FunctionPointer:
Binder\Binder_Lookup.cs (1)
207case TypeKind.FunctionPointer:
Binder\Binder_Operators.cs (3)
606leftType?.TypeKind == TypeKind.FunctionPointer && rightType?.TypeKind == TypeKind.FunctionPointer) 3753else if (targetTypeKind == TypeKind.Pointer || targetTypeKind == TypeKind.FunctionPointer)
Binder\Binder_Statements.cs (2)
2468case TypeKind.FunctionPointer when fromAddressOf: 2471case TypeKind.FunctionPointer:
Binder\Semantics\OverloadResolution\OverloadResolutionResult.cs (1)
1225else if (argument.Kind == BoundKind.MethodGroup && parameterType.TypeKind == TypeKind.FunctionPointer)
CodeGen\EmitExpression.cs (1)
4100Debug.Assert(load.Type is { TypeKind: TypeKind.FunctionPointer });
Compilation\CSharpSemanticModel.cs (1)
2242else if (boundExpr is BoundConversion { ConversionKind: ConversionKind.MethodGroup, Conversion: var exprConversion, Type: { TypeKind: TypeKind.FunctionPointer }, SymbolOpt: var symbol })
Compiler\ClsComplianceChecker.cs (1)
993case TypeKind.FunctionPointer:
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (1)
550case ConversionKind.MethodGroup when oldNodeOpt is { Type: { TypeKind: TypeKind.FunctionPointer } funcPtrType }:
Symbols\Compilation_WellKnownMembers.cs (1)
964case TypeKind.FunctionPointer:
Symbols\ConstraintsHelper.cs (1)
280case TypeKind.FunctionPointer:
Symbols\FunctionPointers\FunctionPointerTypeSymbol.cs (1)
75public override TypeKind TypeKind => TypeKind.FunctionPointer;
Symbols\Metadata\PE\NativeIntegerTypeDecoder.cs (1)
90case TypeKind.FunctionPointer:
Symbols\TypeSymbol.cs (1)
510TypeKind.FunctionPointer => Microsoft.Cci.PrimitiveTypeCode.FunctionPointer,
Symbols\TypeSymbolExtensions.cs (6)
319case TypeKind.FunctionPointer: 400return type.TypeKind == TypeKind.FunctionPointer; 408case TypeKind.FunctionPointer: 929case TypeKind.FunctionPointer: 1282type.VisitType((TypeSymbol t, object? _, bool _) => t.TypeKind is TypeKind.Pointer or TypeKind.FunctionPointer, null) is object; 1519case TypeKind.FunctionPointer:
Utilities\TypeSymbolExtensions.cs (1)
198case TypeKind.FunctionPointer:
Microsoft.CodeAnalysis.CSharp.CodeStyle (1)
src\Analyzers\CSharp\Analyzers\InvokeDelegateWithConditionalAccess\InvokeDelegateWithConditionalAccessAnalyzer.cs (1)
91if (syntaxContext.SemanticModel.GetTypeInfo(invocationExpression.Expression, syntaxContext.CancellationToken).Type is { TypeKind: TypeKind.FunctionPointer })
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (2)
CodeGen\CodeGenFunctionPointersTests.cs (2)
302Assert.Equal(TypeKind.FunctionPointer, field.Type.TypeKind); 378Assert.Equal(TypeKind.FunctionPointer, field.Type.TypeKind);
Microsoft.CodeAnalysis.CSharp.Features (1)
src\Analyzers\CSharp\Analyzers\InvokeDelegateWithConditionalAccess\InvokeDelegateWithConditionalAccessAnalyzer.cs (1)
91if (syntaxContext.SemanticModel.GetTypeInfo(invocationExpression.Expression, syntaxContext.CancellationToken).Type is { TypeKind: TypeKind.FunctionPointer })
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (2)
Semantics\FunctionPointerTests.cs (2)
212Assert.Equal(TypeKind.FunctionPointer, typeInfo.Type!.TypeKind); 298Assert.Equal(TypeKind.FunctionPointer, typeInfo.ConvertedType!.TypeKind);
Microsoft.CodeAnalysis.CSharp.Test.Utilities (1)
FunctionPointerUtilities.cs (1)
29Assert.Equal(TypeKind.FunctionPointer, symbol.TypeKind);
Microsoft.CodeAnalysis.Features (1)
Completion\Providers\AbstractObjectInitializerCompletionProvider.cs (1)
164return type.TypeKind is not (TypeKind.Delegate or TypeKind.Struct or TypeKind.FunctionPointer or TypeKind.Pointer);
Microsoft.CodeAnalysis.VisualBasic (1)
Symbols\NamedTypeSymbol.vb (1)
1272Case TypeKind.Pointer, TypeKind.FunctionPointer
Microsoft.CodeAnalysis.Workspaces (1)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ITypeSymbolExtensions.cs (1)
91=> symbol?.TypeKind == TypeKind.FunctionPointer;
Microsoft.Gen.ContextualOptions (1)
Parser.cs (1)
83.Where(prop => prop.Type.TypeKind != TypeKind.FunctionPointer)
Microsoft.Interop.SourceGeneration (3)
BlittableTypeMarshallingInfoProvider.cs (1)
27if (type.TypeKind is TypeKind.Enum or TypeKind.Pointer or TypeKind.FunctionPointer
ManagedTypeInfo.cs (1)
56if (type.TypeKind == TypeKind.FunctionPointer)
TypeSymbolExtensions.cs (1)
110if (type.TypeKind is TypeKind.Pointer or TypeKind.FunctionPointer)