On Wed, Nov 23, 2011 at 07:39:05AM -0600, Jesse Luehrs wrote: > On Wed, Nov 23, 2011 at 01:17:20PM +0100, Johan Vromans wrote: > > Jesse Luehrs <doy@tozt.net> writes: > > > > > I don't see why using a \N{} sequence should have any impact on what > > > functions are available to use in my code. > > > > Compare: > > > > $ perl -wE 'binmode STDOUT; warn File::Spec->catfile("foo","bar")' > > Can't locate object method "catfile" via package "File::Spec" (perhaps you forgot to load "File::Spec"?) at -e line 1. > > > > with: > > > > $ perl -wE 'STDOUT->binmode; warn File::Spec->catfile("foo","bar")' > > foo/bar at -e line 1. > > Sure, I think that's confusing too. I don't, and I really wish Perl did it more often. Every time I write Some::Class::I::did::not::use -> foo () and Perl tells me "oh, you didn't load Some::Class::I::did::not::use", I think "well, if you know what's missing, why don't you just do it for me". [1] But maybe I'm the only Perl user who appreciates DWIM. Abigail [1] I've no idea wether it's actually feasable, or how to do it if it were.Thread Previous | Thread Next