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
Hi guys,
.net 7 provides generic Attributes, which works as expected. But if you are passing on a generic type from a wrapping class, it shows a CS8968 compiler error. I wonder if you can help me here.
Thanks a lot in advance.
Version Used:
Microsoft Visual Studio Community 2022 (64-bit) - Current Version 17.5.3
.net core: 7.0.202
Steps to Reproduce:
Create a generic class derived from Attribute.
Create another generic class.
Use the type of the attribute within the previously created class, using its generic parameter.
R0boC0p
changed the title
Generic Attribute not possible if passing on generic type
Generic Attribute not possible when passing on generic type
Mar 30, 2023
Hi guys,
.net 7 provides generic Attributes, which works as expected. But if you are passing on a generic type from a wrapping class, it shows a
CS8968
compiler error. I wonder if you can help me here.Thanks a lot in advance.
Version Used:
Microsoft Visual Studio Community 2022 (64-bit) - Current Version 17.5.3
.net core: 7.0.202
Steps to Reproduce:
Attribute
.Expected Behavior:
Generic attribute to work inside a generic class like it would in global scope.
Actual Behavior:
CS8968: 'T' an attribute type argument cannot use type parameters.
The text was updated successfully, but these errors were encountered: