I am trying to create a generic serializer withing a Vnext project and when I call the constructor for StreamWriter it throws this compiler error
Here is the Answer from davidfowl
Thats because it's not available on CoreCLR. Use new StringWriter(File.OpenWrite(path)) instead
For future reference where can I check if a function is available or not?
File issues on the https://github.com/dotnet/corefx repository. They will be able to clarify why things are missing in the new framework. I believe the reason this particular overload was removed was because of layering issues between the new packages.
The assembly that contains StreamWriter shouldn't be directly referencing FileStream:
new StreamReader(path)
actually does
new StreamReader(new FileStream(path, options)).