From: Matthew Pounsett Date: 2010-07-20T05:02:18+09:00 Subject: Adding to the Errno module [accidentally posted this from an non-subscribed address a few minutes ago .. hopefully it doesn't show up twice] I'm trying to add some missing handlers to the Errno module on my system. But, clearly I'm missing something here, as I'm getting an error I don't understand when I try a raise using any of them. My test code: irb(main):001:0> module Errno irb(main):002:1> class EFTYPE < SystemCallError; end irb(main):003:1> end => nil irb(main):004:0> raise Errno::EFTYPE, "trying to raise an error here", caller TypeError: can't convert Module into Integer from (irb):4:in `initialize' from (irb):4:in `exception' from (irb):4:in `raise' from (irb):4 from /opt/local/bin/irb:12:in `
' irb(main):005:0> I'm using things like the webrick standard library as an example here, but clearly I've got something wrong. Anyone have any suggestions? Matt