$34 GRAYBYTE WORDPRESS FILE MANAGER $11

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 172.67.217.254 | ADMIN IP 216.73.216.36
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/opt/alt/ruby26/lib64/ruby/2.6.0/rubygems/core_ext/

HOME
Current File : /opt/alt/ruby26/lib64/ruby/2.6.0/rubygems/core_ext//kernel_warn.rb
# frozen_string_literal: true

# `uplevel` keyword argument of Kernel#warn is available since ruby 2.5.
if RUBY_VERSION >= "2.5"

  module Kernel
    path = "#{__dir__}/" # Frames to be skipped start with this path.

    # Suppress "method redefined" warning
    original_warn = instance_method(:warn)
    Module.new {define_method(:warn, original_warn)}

    original_warn = method(:warn)

    module_function define_method(:warn) {|*messages, uplevel: nil|
      unless uplevel
        return original_warn.call(*messages)
      end

      # Ensure `uplevel` fits a `long`
      uplevel, = [uplevel].pack("l!").unpack("l!")

      if uplevel >= 0
        start = 0
        while uplevel >= 0
          loc, = caller_locations(start, 1)
          unless loc
            # No more backtrace
            start += uplevel
            break
          end

          start += 1

          unless loc.path.start_with?(path)
            # Non-rubygems frames
            uplevel -= 1
          end
        end
        uplevel = start
      end
      original_warn.call(*messages, uplevel: uplevel)
    }
  end
end


Current_dir [ NOT WRITEABLE ] Document_root [ NOT WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
3 Mar 2024 10.47 PM
root / linksafe
0755
kernel_gem.rb
2.507 KB
12 Apr 2022 11.50 AM
root / linksafe
0644
kernel_require.rb
3.927 KB
12 Apr 2022 11.50 AM
root / linksafe
0644
kernel_warn.rb
1.082 KB
12 Apr 2022 11.50 AM
root / linksafe
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF