error FS0192: internal error: null: GetTRefType
It showed up when I tried to run a .fsx script that referenced NuGet.Core 2.1.0, but only when the script was run on Windows Server 2008 R2. Windows 7 x64? No problems. Windows Server 2003/8 x86? No problems.
2008 R2? Bam. Every time.
A bit of trial of error discovered two things:
The error went away if I referenced NuGet.Core 2.2.0 alpha 4
And the minimal error case is pretty minimal:
Looking at the NuGet.Core source ( http://nuget.codeplex.com/SourceControl/changeset/view/5b6d7e16b19c#src%2fCore%2fSemanticVersion.cs ) the only thing that might be a relevant change that I can see is a simplification of some custom GetHashCode logic.
Raising the interesting question of why there is custom GetHashCode logic in the first place, and how the heck did they get it to cause internal F# compiler errors anyway? And why did it only fail on that one specific version of Windows?
All very strange. Hopefully 2.2.0 will be a full release before we want to start using this technique for in our production code!