From: ts Date: 2001-10-03T22:53:48+09:00 Subject: [ruby-talk:22000] Re: Class const in a super class >>>>> "J" == Jim Freeze writes: J> I am trying to define a constant in a superclass, J> but use that const in the base class. pigeon% cat b.rb #!/usr/bin/ruby class Base def initialize puts "classconst: #{type::CLASSCONST}" end end class A1 < Base CLASSCONST = "a1" end class A2 < Base CLASSCONST = "a2" end A1.new A2.new pigeon% pigeon% b.rb classconst: a1 classconst: a2 pigeon% Guy Decoux