Sha256: c09ad1fc2cf26574d20546f6622a70ce6155bd7c904d9b0b406c72280ca670f1

Contents?: true

Size: 179 Bytes

Versions: 34

Compression:

Stored size: 179 Bytes

Contents

User  = Struct.new(:name)
ARRAY = Array.new(3) do
  User.new(sprintf("%010d"), rand(1_000_000_000))
end

ARRAY.sort { |a, b| a.name <=> b.name }
ARRAY.sort_by(&:name)

ARRAY.sort

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
fasterer-0.2.0 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.12 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.11 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.10 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.9 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.8 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.7 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.6 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.5 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.4 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.3 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.2 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.1 spec/support/analyzer/13_sort_vs_sort_by.rb
fasterer-0.1.0 spec/support/analyzer/13_sort_vs_sort_by.rb