Currently, the constructor taking a System.Version treats the fourth number as patch version and the third number as the build metadata. Thus 1.2.3.4 becomes 1.2.4+3. This is counter to the standard .NET practice of taking the third number to be the patch. For example, when assigning versions to NuGet packages.
Any conversion from a four-segment version to a three-segment version is problematic. It breaks the ordering. For example, 1.0.0.0 < 1.0.0.1 but 1.0.0+0 has the same precedence as 1.0.0+1.
Conversion from System.Version should be improved and the existing constructor marked obsolete.
Currently, the constructor taking a
System.Versiontreats the fourth number as patch version and the third number as the build metadata. Thus1.2.3.4becomes1.2.4+3. This is counter to the standard .NET practice of taking the third number to be the patch. For example, when assigning versions to NuGet packages.Any conversion from a four-segment version to a three-segment version is problematic. It breaks the ordering. For example,
1.0.0.0<1.0.0.1but1.0.0+0has the same precedence as1.0.0+1.Conversion from
System.Versionshould be improved and the existing constructor marked obsolete.