@@ -255,7 +255,7 @@ def self.loc_string(loc, compilation_dir, logger)
255255 # Get the diff of two long strings. Call the 'diffy' gem for this.
256256 # @param string1 [String] First string (-)
257257 # @param string2 [String] Second string (+)
258- # @param depth [Fixnum ] Depth, for correct indentation
258+ # @param depth [Integer ] Depth, for correct indentation
259259 # @return Array<String> Displayable result
260260 def self . diff_two_strings_with_diffy ( string1 , string2 , depth )
261261 # Single line strings?
@@ -324,8 +324,8 @@ def self.make_trailing_whitespace_visible(string_in)
324324 # Get the diff of two hashes. Call the 'diffy' gem for this.
325325 # @param hash1 [Hash] First hash (-)
326326 # @param hash1 [Hash] Second hash (+)
327- # @param depth [Fixnum ] Depth, for correct indentation
328- # @param limit [Fixnum ] Maximum string length
327+ # @param depth [Integer ] Depth, for correct indentation
328+ # @param limit [Integer ] Maximum string length
329329 # @param strip_diff [Boolean] Strip leading +/-/" "
330330 # @return [Array<String>] Displayable result
331331 def self . diff_two_hashes_with_diffy ( opts = { } )
@@ -358,7 +358,7 @@ def self.diff_two_hashes_with_diffy(opts = {})
358358 end
359359
360360 # Special case: addition only, no truncation
361- # @param depth [Fixnum ] Depth, for correct indentation
361+ # @param depth [Integer ] Depth, for correct indentation
362362 # @param hash [Hash] Added object
363363 # @return [Array<String>] Displayable result
364364 def self . addition_only_no_truncation ( depth , hash )
@@ -383,7 +383,7 @@ def self.addition_only_no_truncation(depth, hash)
383383
384384 # Limit length of a string
385385 # @param str [String] String
386- # @param limit [Fixnum ] Limit (0=unlimited)
386+ # @param limit [Integer ] Limit (0=unlimited)
387387 # @return [String] Truncated string
388388 def self . truncate_string ( str , limit )
389389 return str if limit . nil? || str . length <= limit
@@ -392,7 +392,7 @@ def self.truncate_string(str, limit)
392392
393393 # Get the diff between two hashes. This is recursive-aware.
394394 # @param obj [diff object] diff object
395- # @param depth [Fixnum ] Depth of nesting, used for indentation
395+ # @param depth [Integer ] Depth of nesting, used for indentation
396396 # @return Array<String> Printable diff outputs
397397 def self . hash_diff ( obj , depth , key_in , nested = false )
398398 result = [ ]
@@ -417,7 +417,7 @@ def self.hash_diff(obj, depth, key_in, nested = false)
417417 end
418418
419419 # Get the diff between two arbitrary objects
420- # @param depth [Fixnum ] Depth of nesting, used for indentation
420+ # @param depth [Integer ] Depth of nesting, used for indentation
421421 # @param old_obj [?] Old object
422422 # @param new_obj [?] New object
423423 # @return Array<String> Diff output
@@ -432,7 +432,7 @@ def self.diff_at_depth(depth, old_obj, new_obj)
432432
433433 # Utility Method!
434434 # Indent a given text string with a certain number of spaces
435- # @param spaces [Fixnum ] Number of spaces
435+ # @param spaces [Integer ] Number of spaces
436436 # @param text [String] Text
437437 def self . left_pad ( spaces , text = '' )
438438 [ ' ' * spaces , text ] . join ( '' )
@@ -447,7 +447,7 @@ def self.left_pad(spaces, text = '')
447447 def self . stringify_for_diffy ( obj )
448448 return JSON . pretty_generate ( obj ) if [ Hash , Array ] . include? ( obj . class )
449449 return '""' if obj . is_a? ( String ) && obj == ''
450- return obj if [ String , Fixnum , Float ] . include? ( obj . class )
450+ return obj if [ String , Integer , Float ] . include? ( obj . class )
451451 "#{ obj . class } : #{ obj . inspect } "
452452 end
453453
@@ -512,8 +512,8 @@ def self._adjust_for_display_datatype(obj1, obj2, option, logger)
512512 return [ '""' , 'undef' ] if obj2 . nil?
513513
514514 # If one is an integer and the other is a string
515- return [ obj1 , "\" #{ obj2 } \" " ] if obj1 . is_a? ( Fixnum ) && obj2 . is_a? ( String )
516- return [ "\" #{ obj1 } \" " , obj2 ] if obj1 . is_a? ( String ) && obj2 . is_a? ( Fixnum )
515+ return [ obj1 , "\" #{ obj2 } \" " ] if obj1 . is_a? ( Integer ) && obj2 . is_a? ( String )
516+ return [ "\" #{ obj1 } \" " , obj2 ] if obj1 . is_a? ( String ) && obj2 . is_a? ( Integer )
517517
518518 # True and false
519519 return [ obj1 , "\" #{ obj2 } \" " ] if obj1 . is_a? ( TrueClass ) && obj2 . is_a? ( String )
0 commit comments