Sha256: 26c389522810891783f2a863f1b7c7c5e0d96ac6a5c918f03400000ff7728a18
Contents?: true
Size: 475 Bytes
Versions: 10
Compression:
Stored size: 475 Bytes
Contents
# frozen_string_literal: true module RubyVersionCheck # Allows maintaining version compatibility with older versions of Ruby # :nocov: def self.ruby_version2? @ruby_version2 ||= ( Gem::Version.new(RUBY_VERSION) >= Gem::Version.new("2.0.0") && Gem::Version.new(RUBY_VERSION) < Gem::Version.new("3.0.0") ) end def self.ruby_version3? @ruby_version3 ||= (Gem::Version.new(RUBY_VERSION) >= Gem::Version.new("3.0.0")) end # :nocov: end
Version data entries
10 entries across 10 versions & 2 rubygems