aboutsummaryrefslogtreecommitdiffstats
path: root/benchmark
diff options
context:
space:
mode:
authork0kubun <k0kubun@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-07-08 04:12:04 +0000
committerk0kubun <k0kubun@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-07-08 04:12:04 +0000
commit84ad0b1440eea96cef5a27f572d544770cc99f6f (patch)
tree2fc36bac7caee02436e0a94e1f47648b73e3ced3 /benchmark
parent41bf9cd8eb6c5a1d83b4b551362559b0e8666b40 (diff)
downloadruby-84ad0b1440eea96cef5a27f572d544770cc99f6f.tar.gz
benchmark/driver.rb: simplify LoadError handling
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63882 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'benchmark')
-rwxr-xr-xbenchmark/driver.rb11
1 files changed, 2 insertions, 9 deletions
diff --git a/benchmark/driver.rb b/benchmark/driver.rb
index 0215d7676d..c166c80edb 100755
--- a/benchmark/driver.rb
+++ b/benchmark/driver.rb
@@ -3,18 +3,11 @@
# Ruby Benchmark driver
#
-first = true
-
begin
require 'optparse'
rescue LoadError
- if first
- first = false
- $:.unshift File.join(File.dirname(__FILE__), '../lib')
- retry
- else
- raise
- end
+ $:.unshift File.join(File.dirname(__FILE__), '../lib')
+ require 'optparse'
end
require 'benchmark'