Skip to content

Commit 2e34b37

Browse files
committed
Remove Fixnum and Bignum constants
1 parent dd0c59d commit 2e34b37

File tree

5 files changed

+3
-7
lines changed

5 files changed

+3
-7
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ Compatibility:
5454
* Limit maximum encoding set size by 256 (#3039, @thomasmarshall, @goyox86).
5555
* Remove deprecated methods `Dir.exists?`, `File.exists?`, and `Kernel#=~` (#3039, @patricklinpl, @nirvdrum).
5656
* Remove deprecated `FileTest.exists?` method (#3039, @andrykonchin).
57+
* Remove deprecated `Fixnum` and `Bignum` constants (#3039, @andrykonchin).
5758

5859
Performance:
5960

bench/asciidoctor/asciidoctor/lib/asciidoctor/document.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ def initialize data = nil, options = {}
225225
# safely resolve the safe mode from const, int or string
226226
if !(safe_mode = options[:safe])
227227
@safe = SafeMode::SECURE
228-
elsif ::Fixnum === safe_mode
228+
elsif ::Integer === safe_mode # this is fixed in upstream in v1.5.5 (https://github.com/asciidoctor/asciidoctor/blob/main/CHANGELOG.adoc#155-2016-10-05---mojavelinux)
229229
# be permissive in case API user wants to define new levels
230230
@safe = safe_mode
231231
else

spec/ffi/fixtures/compile.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ module TestLibrary
1111
CPU = case RbConfig::CONFIG['host_cpu'].downcase
1212
when /i[3456]86/
1313
# Darwin always reports i686, even when running in 64bit mode
14-
if RbConfig::CONFIG['host_os'] =~ /darwin/ && 0xfee1deadbeef.is_a?(Fixnum)
14+
if RbConfig::CONFIG['host_os'] =~ /darwin/ && [1].pack("J").bytesize == 8
1515
"x86_64"
1616
else
1717
"i386"

spec/tags/core/integer/constants_tags.txt

Lines changed: 0 additions & 2 deletions
This file was deleted.

src/main/ruby/truffleruby/core/integer.rb

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@
3434
# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
3535
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3636

37-
Fixnum = Bignum = Integer
38-
Object.deprecate_constant :Fixnum, :Bignum
39-
4037
class Integer < Numeric
4138

4239
# Have a copy in Integer of the Numeric version, as MRI does

0 commit comments

Comments
 (0)