Skip to content

Remove checks for RUBY_VERSION #141

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions lib/cgi.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@
# Documentation: Wakou Aoyama (RDoc'd and embellished by William Webber)
#

raise "Please, use ruby 1.9.0 or later." if RUBY_VERSION < "1.9.0"

# == Overview
#
# The Common Gateway Interface (CGI) is a simple protocol for passing an HTTP
Expand Down
13 changes: 3 additions & 10 deletions lib/drb/drb.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1545,16 +1545,9 @@ def perform_without_block

end

if RUBY_VERSION >= '1.8'
require 'drb/invokemethod'
class InvokeMethod
include InvokeMethod18Mixin
end
else
require 'drb/invokemethod16'
class InvokeMethod
include InvokeMethod16Mixin
end
require 'drb/invokemethod'
class InvokeMethod
include InvokeMethod18Mixin
end

# The main loop performed by a DRbServer's internal thread.
Expand Down
8 changes: 2 additions & 6 deletions lib/irb/init.rb
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,6 @@ def IRB.init_error
@CONF[:LC_MESSAGES].load("irb/error.rb")
end

FEATURE_IOPT_CHANGE_VERSION = "1.9.0"

# option analyzing
def IRB.parse_opts
load_path = []
Expand Down Expand Up @@ -220,10 +218,8 @@ def IRB.parse_opts
break
end
end
if RUBY_VERSION >= FEATURE_IOPT_CHANGE_VERSION
load_path.collect! do |path|
/\A\.\// =~ path ? path : File.expand_path(path)
end
load_path.collect! do |path|
/\A\.\// =~ path ? path : File.expand_path(path)
end
$LOAD_PATH.unshift(*load_path)

Expand Down
5 changes: 0 additions & 5 deletions lib/open-uri.rb
Original file line number Diff line number Diff line change
Expand Up @@ -249,11 +249,6 @@ def OpenURI.open_http(buf, target, proxy, options) # :nodoc:
raise "Non-HTTP proxy URI: #{proxy_uri}" if proxy_uri.class != URI::HTTP
end

if target.userinfo && "1.9.0" <= RUBY_VERSION
# don't raise for 1.8 because compatibility.
raise ArgumentError, "userinfo not supported. [RFC3986]"
end

header = {}
options.each {|k, v| header[k] = v if String === k }

Expand Down
2 changes: 0 additions & 2 deletions lib/webrick/httpproxy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
require "webrick/httpserver"
require "net/http"

Net::HTTP::version_1_2 if RUBY_VERSION < "1.7"

module WEBrick
NullReader = Object.new
class << NullReader
Expand Down