Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RZ1017 when using where in a @typeparam constraint #8788

Closed
chsienki opened this issue Jun 1, 2023 · 1 comment
Closed

RZ1017 when using where in a @typeparam constraint #8788

chsienki opened this issue Jun 1, 2023 · 1 comment
Labels
area-blazor area-compiler Umbrella for all compiler issues

Comments

@chsienki
Copy link
Member

chsienki commented Jun 1, 2023

When adding a where clause to a @typeparam directive the IDE shows error RZ1017 but the code compiles correctly.

Repro steps:

  1. Create a new Blazor Server App, target framework net6.0
  2. Open Counter.razor
  3. Add:
@typeparam T1
@typeparam T2 where T2 : T1
  1. Observe the error
  2. F5 compiles successfully
image

Interestingly changing the target framework to 8.0 seems to fix the issue, and remains fixed even after switching back to 6.0.

Also reported here: https://stackoverflow.com/questions/72095268/net6-blazor-typeparam-where-constraint-error-rz1017

@ghost ghost added the untriaged label Jun 1, 2023
@chsienki chsienki changed the title RZ1017 when using ' RZ1017 when using 'where` in a @typeparam constraint Jun 1, 2023
@chsienki chsienki changed the title RZ1017 when using 'where` in a @typeparam constraint RZ1017 when using where in a @typeparam constraint Jun 1, 2023
@phil-allen-msft phil-allen-msft added the area-compiler Umbrella for all compiler issues label Jun 1, 2023
@chsienki
Copy link
Member Author

chsienki commented Jun 2, 2023

Closing as a dupe of #8572

@chsienki chsienki closed this as not planned Won't fix, can't repro, duplicate, stale Jun 2, 2023
@ghost ghost removed the untriaged label Jun 2, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Jul 2, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-blazor area-compiler Umbrella for all compiler issues
Projects
None yet
Development

No branches or pull requests

2 participants