summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/debug.rb16
-rw-r--r--lib/optparse.rb12
2 files changed, 20 insertions, 8 deletions
diff --git a/lib/debug.rb b/lib/debug.rb
index 1b558ab90f..0caeecb00c 100644
--- a/lib/debug.rb
+++ b/lib/debug.rb
@@ -781,8 +781,8 @@ class << DEBUGGER__
saved_crit = Thread.critical
Thread.critical = true
make_thread_list
- for th in @thread_list
- context(th[0]).set_trace arg
+ for th, in @thread_list
+ context(th).set_trace arg
end
Thread.critical = saved_crit
arg
@@ -796,9 +796,9 @@ class << DEBUGGER__
saved_crit = Thread.critical
Thread.critical = true
make_thread_list
- for th in @thread_list
- next if th[0] == Thread.current
- context(th[0]).set_suspend
+ for th, in @thread_list
+ next if th == Thread.current
+ context(th).set_suspend
end
Thread.critical = saved_crit
# Schedule other threads to suspend as soon as possible.
@@ -809,9 +809,9 @@ class << DEBUGGER__
saved_crit = Thread.critical
Thread.critical = true
make_thread_list
- for th in @thread_list
- next if th[0] == Thread.current
- context(th[0]).clear_suspend
+ for th, in @thread_list
+ next if th == Thread.current
+ context(th).clear_suspend
end
waiting.each do |th|
th.run
diff --git a/lib/optparse.rb b/lib/optparse.rb
index de88b648ec..a5905d2d4b 100644
--- a/lib/optparse.rb
+++ b/lib/optparse.rb
@@ -414,7 +414,11 @@ summary feature.
pat = t if t.respond_to?(:match)
end
unless block
+<<<<<<< optparse.rb
+ block = pat.method(:convert).to_block if pat.respond_to?(:convert)
+=======
block = pat.method(:convert).to_block if pat.respond_to?(:convert)
+>>>>>>> 1.19
end
@atype[t] = [pat, block]
end
@@ -949,7 +953,11 @@ Default options, which never appear in option summary.
# directly specified pattern(any object possible to match)
if !(String === o) and o.respond_to?(:match)
pattern = notwice(o, pattern, 'pattern')
+<<<<<<< optparse.rb
+ conv = (pattern.method(:convert).to_block if pattern.respond_to?(:convert))
+=======
conv = (pattern.method(:convert).to_block if pattern.respond_to?(:convert))
+>>>>>>> 1.19
next
end
@@ -962,7 +970,11 @@ Default options, which never appear in option summary.
when CompletingHash
when nil
pattern = CompletingHash.new
+<<<<<<< optparse.rb
+ conv = (pattern.method(:convert).to_block if pattern.respond_to?(:convert))
+=======
conv = (pattern.method(:convert).to_block if pattern.respond_to?(:convert))
+>>>>>>> 1.19
else
raise ArgumentError, "argument pattern given twice"
end