Description
Versions Used:
- Visual Studio 2019 RTM Community for Windows (16.0.0)
- .Net Core 3.0.100-preview4-010963
- Local build of master, commit hash: 336c3766c5bdb87f313c8df89938957b93239fac
Steps to Reproduce:
- Write a simple program using the Default Interface Implementation feature:
class Program {
static void Main(string[] args) {
IFoo x = new Baz();
Console.WriteLine(x.Bar());
}
}
public interface IFoo { int Bar() => 42; }
public class Baz : IFoo { }
Environment The project is targeting .Net Core 3.0. The 'Use previews of the .Net Core SDK' option is enabled in the experimental instance and main instance. .Net Core 3.0.100-preview4-010963 installed as the highest .Net Core SDK version. Local build of Roslyn's master branch installed in the experimental instance from a RoslynDeployment.vsix build in debug mode. The project explicitly specifies the C# language version '8.0'.
Expected Behavior:
- No IDE warnings or errors, compiles and runs.
Actual Behavior:
- No IDE warnings or errors, but the compiler produces the following error:
1>C:\Program Files\dotnet\sdk\3.0.100-preview4-010963\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.RuntimeIdentifierInference.targets(151,5): message NETSDK1057: You are using a preview version of .NET Core. See: https://aka.ms/dotnet-core-preview
1>Program.cs(13,29,13,32): error CS0531: 'IFoo.Bar()': interface members cannot have a definition
1>Program.cs(14,20,14,24): error CS0535: 'Baz' does not implement interface member 'IFoo.Bar()'
1>Done building project "ConsoleApp2.csproj" -- FAILED.
The code compiles and runs fine when I use the locally compiled compiler directly. It doesn't look like Visual Studio is invoking the compiler from the VSIX. I have verified the VSIX is installed correctly and the editor is behaving properly with the installed extension.
Does anyone have any tips? Not sure if something changed with the deployables for VS 2019.
Thank you.