新版本的变更 / Ruby 3.2

# requires Ruby 3.2 or newer

# *** before: ***
PointOld = Struct.new(:x, :y, keyword_init: true# keyword-only had to be
#explicit

# *** in version 3.2: ***
Point = Struct.new(:x, :y)

puts Point.new(12).inspect          # positional still works
puts Point.new(x: 1, y: 2).inspect    # and so does keyword init, automatically