Reputation: 2985
I'm trying to deploy on .net 4.6 (which is what azure apps use), so I'm referencing the latest fsharp.core compatible with that framework on my .fsproj
, which is <TargetFSharpCoreVersion>4.4.0.0</TargetFSharpCoreVersion>
But on my code I'm using Suave 2.0.0-rc8, which references some fsharp.core 4.0.0.1
, the one that is available from nuget.
But somehow, it works! Can anybody give me an explanation even if it is a bit simplistic of how it works? How can there be two fsharp.cores, it seems it is not as core as it sounds.
:s
Upvotes: 4
Views: 328
Reputation: 233125
The NuGet version of FSharp.Core is not equal to the assembly version of FSharp.Core.
The versioning scheme for FSharp.Core is confusing, but when you use FSharp.Core in a .NET 4.6 application, the assembly version is 4.4.0.0, even though it's bundled in a NuGet package with the version 4.0.0.1.
You can investigate this yourself inside of Visual Studio. As an example, I have a small application that has these NuGet dependencies:
Id Versions
-- --------
FsCheck {2.6.2}
FsCheck.Xunit {2.6.2}
FSharp.Core {4.0.0.1}
Unquote {3.1.2}
xunit.abstractions {2.0.0}
xunit.extensibility.core {2.1.0}
xunit.extensibility.execution {2.1.0}
You will notice that the NuGet version of FSharp.Core is 4.0.0.1.
If you find the reference in Solution Explorer, you can find the actual .dll
file that contains FSharp.Core. If you open this with Reflector or the Visual Studio object browser, you'll see that the assembly version is, in fact, 4.4.0.0.
Upvotes: 3