dotnet / razor

Compiler and tooling experience for Razor ASP.NET Core apps in Visual Studio, Visual Studio for Mac, and VS Code.
https://asp.net
MIT License
507 stars 196 forks source link

Support FAR in cohosting #11238

Open davidwengier opened 5 days ago

davidwengier commented 5 days ago

Fixes https://github.com/dotnet/razor/issues/11237 Needs https://github.com/dotnet/roslyn/pull/76002 and a version bump

Very simple one, though I was a little cheeky. There is basically no code that could be shared, except for code that removes __o and k_BackingField from the results, but those methods operate on VS LSP types. Given cohosting largely uses Roslyn LSP types, and will be exclusively FUSE, and FUSE doesn't have __o, I just skipped that bit. Confirmed in VS that having cohosting and FUSE on makes for nice looking results with no generated code artifacts.

Side note: I don't think anything will ever have k_BackingField in the results, but there is zero test coverage so who knows! 😁