Sha256: e73b6d83a0179a46e2a04a568222a7bb3cb16de16c8399f3126fd0522120b29d

Contents?: true

Size: 435 Bytes

Versions: 24

Compression:

Stored size: 435 Bytes

Contents

#--
# Extensions to fixnum to define some constants missing from Ruby itself

class Fixnum

  unless constants.include? :MAX

    # future versions of Ruby may end up defining this constant
    # in a more portable way, as documented by Matz himself in:
    #
    #   https://bugs.ruby-lang.org/issues/7517
    #
    # ... but until such time, we define the constant ourselves
    MAX = (2**(0.size * 8 - 2) - 1) # :nodoc:

  end

end

Version data entries

24 entries across 24 versions & 9 rubygems

Version Path
abaci-0.3.0 vendor/bundle/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
arcabouco-0.2.13 vendor/bundle/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
tdiary-5.0.2 vendor/bundle/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-delta-1.1.0 vendor/bundle/jruby/2.2.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-delta-1.0.1 vendor/bundle/jruby/2.2.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-base64-1.0.4 vendor/bundle/jruby/2.2.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-base64-1.0.3 vendor/bundle/jruby/2.2.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-delta-1.0.0 vendor/bundle/jruby/2.2.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-base64-1.0.2 vendor/bundle/jruby/2.3.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-base64-1.0.1 vendor/bundle/jruby/2.3.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
logstash-filter-base64-1.0.0 vendor/bundle/jruby/2.3.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
vagrant-unbundled-1.8.5.2 vendor/bundle/ruby/2.3.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
vagrant-unbundled-1.8.5.1 vendor/bundle/ruby/2.3.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
vagrant-unbundled-1.8.4.2 vendor/bundle/ruby/2.3.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
vagrant-unbundled-1.8.4.1 vendor/bundle/ruby/2.3.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
tdiary-5.0.1 vendor/bundle/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
windows-pr-1.2.5 vendor/bundle/ruby/2.2.0/gems/rake-11.2.2/lib/rake/ext/fixnum.rb
rake-11.2.2 lib/rake/ext/fixnum.rb
rake-11.2.0 lib/rake/ext/fixnum.rb
ish_lib_manager-0.0.1 test/dummy/vendor/bundle/ruby/2.3.0/gems/rake-11.1.2/lib/rake/ext/fixnum.rb