From: Niklas Frykholm Date: 2001-09-23T17:07:04+09:00 Subject: [ruby-talk:21592] Re: What's the "Data" class? Don't we need a namespace for standard classes? [Ryo Furue] > class Data > def hello > puts "hello" > end > end > > d = Data.new > d.hello > > The error message was > > ./try.rb:9: undefined method `new' for Data:Class (NameError) > > After a lot of trial and error, I finally found that the code works if > I replace "Data" with "MyData". I guess "Data" is some predefined > class. I looked into the pickaxe Ruby book but couldn't find it. It is a class used internally by Ruby to represent C pointers from extensions. I'm not sure why it is exported to the script namespace. // Niklas