You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#pragma warning disable IL2067// 'type' argument does not satisfy 'DynamicallyAccessedMemberTypes.PublicConstructors' in call to 'ServiceRegistration.ServiceRegistration(Type)'
Copy file name to clipboardExpand all lines: src/Cake.Generator.Core/CakeGenerator.Generate.Helper.Services.Modules.ServiceCollectionAdapter.cs
+3-1Lines changed: 3 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ private sealed class ServiceRegistration : ICakeRegistrationBuilder
14
14
public Type? ServiceType { get; set; }
15
15
public ServiceLifetime Lifetime { get; set; }
16
16
17
-
public ServiceRegistration(Type implementationType)
17
+
public ServiceRegistration([System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicConstructors)] Type implementationType)
18
18
{
19
19
ImplementationType = implementationType;
20
20
}
@@ -69,11 +69,13 @@ public ICakeRegistrationBuilder RegisterInstance<TImplementation>(TImplementatio
69
69
70
70
public ICakeRegistrationBuilder RegisterType(Type type)
71
71
{
72
+
#pragma warning disable IL2067 // 'type' argument does not satisfy 'DynamicallyAccessedMemberTypes.PublicConstructors' in call to 'ServiceRegistration.ServiceRegistration(Type)'
0 commit comments