aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/version.rb
diff options
context:
space:
mode:
authorMisty De Meo2016-11-03 16:28:16 -0700
committerMisty De Meo2016-11-10 15:08:36 -0800
commit9bac107b31f05cca65d8aab23be05e1b867bd289 (patch)
treef6e7684d7fe576b742a3d322d7426613c8aebb9b /Library/Homebrew/version.rb
parentc2815fbb9af4fe4518246cba7df418935fd3b711 (diff)
downloadbrew-9bac107b31f05cca65d8aab23be05e1b867bd289.tar.bz2
Add Version::NULL singleton
Diffstat (limited to 'Library/Homebrew/version.rb')
-rw-r--r--Library/Homebrew/version.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/Library/Homebrew/version.rb b/Library/Homebrew/version.rb
index 60a833609..433964dc7 100644
--- a/Library/Homebrew/version.rb
+++ b/Library/Homebrew/version.rb
@@ -1,3 +1,5 @@
+require "version/null"
+
class Version
include Comparable
@@ -206,6 +208,10 @@ class Version
false
end
+ def null?
+ false
+ end
+
def <=>(other)
return unless other.is_a?(Version)
return 0 if version == other.version