5 instantiations of MethodParameterValue
ILLink.RoslynAnalyzer (5)
TrimAnalysis\FlowAnnotations.cs (3)
267=> new MethodParameterValue(new(method, parameterIndex), dynamicallyAccessedMemberTypes); 270=> new MethodParameterValue(param, GetMethodParameterAnnotation(param)); 273=> new MethodParameterValue(param, dynamicallyAccessedMemberTypes);
TrimAnalysis\TrimAnalysisVisitor.cs (2)
155return new MethodParameterValue(new ParameterProxy(new(method), (ParameterIndex)0)); 259return new MethodParameterValue(new ParameterProxy(parameter, parameter.ContainingSymbol as IMethodSymbol ?? (IMethodSymbol)OwningSymbol));
48 references to MethodParameterValue
ILLink.RoslynAnalyzer (48)
src\tools\illink\src\ILLink.Shared\Annotations.cs (22)
101(MethodParameterValue maybeThisSource, MethodParameterValue maybeThisTarget) when maybeThisSource.IsThisParameter() && maybeThisTarget.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchThisParameterTargetsThisParameter, 102(MethodParameterValue maybeThis, MethodParameterValue) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchThisParameterTargetsParameter, 103(MethodParameterValue maybeThis, MethodReturnValue) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchThisParameterTargetsMethodReturnType, 104(MethodParameterValue maybeThis, FieldValue) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchThisParameterTargetsField, 105(MethodParameterValue maybeThis, GenericParameterValue) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchThisParameterTargetsGenericParameter, 106(MethodParameterValue, MethodParameterValue maybeThis) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchParameterTargetsThisParameter, 107(MethodParameterValue, MethodParameterValue) => DiagnosticId.DynamicallyAccessedMembersMismatchParameterTargetsParameter, 108(MethodParameterValue, MethodReturnValue) => DiagnosticId.DynamicallyAccessedMembersMismatchParameterTargetsMethodReturnType, 109(MethodParameterValue, FieldValue) => DiagnosticId.DynamicallyAccessedMembersMismatchParameterTargetsField, 110(MethodParameterValue, GenericParameterValue) => DiagnosticId.DynamicallyAccessedMembersMismatchParameterTargetsGenericParameter, 111(MethodReturnValue, MethodParameterValue maybeThis) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchMethodReturnTypeTargetsThisParameter, 112(MethodReturnValue, MethodParameterValue) => DiagnosticId.DynamicallyAccessedMembersMismatchMethodReturnTypeTargetsParameter, 116(FieldValue, MethodParameterValue maybeThis) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchFieldTargetsThisParameter, 117(FieldValue, MethodParameterValue) => DiagnosticId.DynamicallyAccessedMembersMismatchFieldTargetsParameter, 121(GenericParameterValue, MethodParameterValue maybeThis) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchTypeArgumentTargetsThisParameter, 122(GenericParameterValue, MethodParameterValue) => DiagnosticId.DynamicallyAccessedMembersMismatchTypeArgumentTargetsParameter, 126(NullableValueWithDynamicallyAccessedMembers, MethodParameterValue maybeThis) when maybeThis.IsThisParameter() => DiagnosticId.DynamicallyAccessedMembersMismatchTypeArgumentTargetsThisParameter, 127(NullableValueWithDynamicallyAccessedMembers, MethodParameterValue) => DiagnosticId.DynamicallyAccessedMembersMismatchTypeArgumentTargetsParameter,
src\tools\illink\src\ILLink.Shared\TrimAnalysis\FlowAnnotations.cs (4)
30internal partial MethodParameterValue GetMethodThisParameterValue(MethodProxy method, DynamicallyAccessedMemberTypes dynamicallyAccessedMemberTypes); 32internal partial MethodParameterValue GetMethodThisParameterValue(MethodProxy method); 34internal partial MethodParameterValue GetMethodParameterValue(ParameterProxy param, DynamicallyAccessedMemberTypes dynamicallyAccessedMemberTypes); 36internal partial MethodParameterValue GetMethodParameterValue(ParameterProxy param);
src\tools\illink\src\ILLink.Shared\TrimAnalysis\HandleCallAction.cs (13)
247var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, DynamicallyAccessedMemberTypes.Interfaces); 295var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, DynamicallyAccessedMemberTypes.Interfaces); 439var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, memberTypes); 482var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, memberTypes); 564var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, requiredMemberTypes); 606var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, GetDynamicallyAccessedMemberTypesFromBindingFlagsForMethods(bindingFlags)); 694var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, GetDynamicallyAccessedMemberTypesFromBindingFlagsForNestedTypes(bindingFlags)); 777var targetValue = _annotations.GetMethodParameterValue(new(calledMethod, (ParameterIndex)1), requiredMemberTypes); 840var targetValue = _annotations.GetMethodParameterValue(new(calledMethod, (ParameterIndex)0), DynamicallyAccessedMemberTypes.PublicParameterlessConstructor); 910var targetValue = _annotations.GetMethodParameterValue(new(calledMethod, (ParameterIndex)1), memberTypes); 956var targetValue = _annotations.GetMethodParameterValue( 1331var targetValue = _annotations.GetMethodThisParameterValue(calledMethod, requiredMemberTypes); 1455var targetValue = _annotations.GetMethodParameterValue(new(calledMethod, (ParameterIndex)0), requiredMemberTypes);
src\tools\illink\src\ILLink.Shared\TrimAnalysis\RequireDynamicallyAccessedMembersAction.cs (2)
81MethodParameterValue maybeThis when maybeThis.IsThisParameter() => DiagnosticId.ImplicitThisCannotBeStaticallyDetermined, 82MethodParameterValue => DiagnosticId.MethodParameterCannotBeStaticallyDetermined,
TrimAnalysis\DiagnosticContext.cs (2)
56MethodParameterValue maybeThisParameter when maybeThisParameter.Parameter.IsImplicitThis => maybeThisParameter.MethodSymbol, 57MethodParameterValue methodParameter => methodParameter.Parameter.ParameterSymbol!,
TrimAnalysis\FlowAnnotations.cs (5)
250internal partial MethodParameterValue GetMethodThisParameterValue(MethodProxy method, DynamicallyAccessedMemberTypes dynamicallyAccessedMemberTypes) 257internal partial MethodParameterValue GetMethodThisParameterValue(MethodProxy method) 266internal MethodParameterValue GetMethodParameterValue(MethodProxy method, ParameterIndex parameterIndex, DynamicallyAccessedMemberTypes dynamicallyAccessedMemberTypes) 269internal partial MethodParameterValue GetMethodParameterValue(ParameterProxy param) 272internal partial MethodParameterValue GetMethodParameterValue(ParameterProxy param, DynamicallyAccessedMemberTypes dynamicallyAccessedMemberTypes)