Skip to content

Better Conversion from System.Version #32

Closed
@WalkerCodeRanger

Description

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.

Metadata

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions