Why does a class inherit from a struct

Viewed 1974

Is

class A < Struct.new(:att)
end

the same as

class A
  attr_accessor :att
end

in Ruby?

2 Answers
Related