mirror of
https://github.com/ruby/ruby.git
synced 2025-09-16 00:54:01 +02:00
Suppress warning for shadowing outer local variable
This commit is contained in:
parent
bfa4073dc2
commit
ebd44ef570
1 changed files with 3 additions and 3 deletions
|
@ -729,9 +729,9 @@ eom
|
|||
%w[
|
||||
CLOCK_THREAD_CPUTIME_ID CLOCK_PROCESS_CPUTIME_ID
|
||||
CLOCK_MONOTONIC
|
||||
].find do |clk|
|
||||
if Process.const_defined?(clk)
|
||||
[clk.to_sym, Process.const_get(clk)].find do |clk|
|
||||
].find do |c|
|
||||
if Process.const_defined?(c)
|
||||
[c.to_sym, Process.const_get(c)].find do |clk|
|
||||
Process.clock_gettime(clk)
|
||||
rescue
|
||||
# Constants may be defined but not implemented, e.g., mingw.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue