Fix build when using source generators#6534
Conversation
|
Nice! Can you please share binlogs generated before and after the change? It would be great to add a test to dotnet/sdk (I guess here https://github.com/dotnet/sdk/tree/main/src/Assets/TestProjects) that creates a simple WPF app with a source generator. The test will be failing until this change is merged and flown through. @singhashish-wpf we'd want this fix serviced into 6.0. |
Sure. Here's the binlogs + the project I used: WpfAppSourceGenerator.zip
I'll take a look at adding a test project. |
|
Thank you! |
Fix build when using source generators (#6534)
Fixes #6522
Fixes dotnet/roslyn#60257
Description
Fixes the build when using source generators.
Customer Impact
Without this PR, customers cannot build a WPF application with source generators.
Regression
No. To my knowledge, it never worked.
Testing
Tested by building a blank WPF application that uses the Regex source generator. This PR fixed the build.
Risk
Low.
/cc @RussKie (It looks like your hunch about the
Analyzersproperty was right)Microsoft Reviewers: Open in CodeFlow