Project

General

Profile

Bug #1163 ยป gem_prelude_raise_right_error.patch

moro (Kyosuke MOROHASHI), 02/15/2009 07:54 PM

View differences:

gem_prelude.rb
requirement, version = version_requirements[0].split
requirement.strip!
if requirement == ">" || requirement == ">="
if (GemVersions[gem_name] <=> Gem.calculate_integers_for_gem_version(version)) >= 0
return false
end
elsif requirement == "~>"
loaded_version = GemVersions[gem_name]
required_version = Gem.calculate_integers_for_gem_version(version)
if loaded_version && (loaded_version[0] == required_version[0])
return false
if loaded_version = GemVersions[gem_name]
if requirement == ">" || requirement == ">="
if (GemVersions[gem_name] <=> Gem.calculate_integers_for_gem_version(version)) >= 0
return false
end
elsif requirement == "~>"
required_version = Gem.calculate_integers_for_gem_version(version)
if (loaded_version[0] == required_version[0])
return false
end
end
end
    (1-1/1)