From: Trans Date: 2007-12-21T06:48:33+09:00 Subject: Selector Namespaces on a file basis? Would it be possible to do selector namespaces on a file basis? That is to say, load a library such that it would only apply to the immediate file and no other? For example lets say I have: # round.rb class Float def round 0 end end # foo.rb n = 1.23 puts n.round #boo.rb selector_require "round" # hypothetical require "foo" n = 1.234 puts n.to_f running boo.rb, we'd get: 1 0 The 1 comes from foo.rb, but the 0 from boo.rb because we "selectively loaded" round.rb. I've never been satisfied with block-oriented approaches often cited. Is this perhaps a more useful approach? Or does this have problems of it own? Thanks, T.