SemVersion: fix operators >/<
parent
0e17216cc9
commit
1b922b8096
|
@ -2,8 +2,10 @@
|
|||
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using Jint.Parser.Ast;
|
||||
using ln.build.semver;
|
||||
using Microsoft.VisualBasic;
|
||||
|
||||
|
@ -81,6 +83,9 @@ namespace ln.build.semver
|
|||
|
||||
public static bool operator <(SemVersion a,SemVersion b)
|
||||
{
|
||||
if (a is null || b is null)
|
||||
return false;
|
||||
|
||||
if (a.Major < b.Major)
|
||||
return true;
|
||||
if (a.Major > b.Major)
|
||||
|
@ -108,6 +113,9 @@ namespace ln.build.semver
|
|||
}
|
||||
public static bool operator >(SemVersion b,SemVersion a)
|
||||
{
|
||||
if (a is null || b is null)
|
||||
return false;
|
||||
|
||||
if (a.Major < b.Major)
|
||||
return true;
|
||||
if (a.Major > b.Major)
|
||||
|
|
Loading…
Reference in New Issue