RE: Eval for module

2003-08-14 Thread Dan Muey
> HI howdy again! > > I forgot to ask: > > Whenever I've tried to do: > > eval { use module; }; > if($@) . > > It always fails and I can't trap it it to , say, try a > different module if it's not found or otherwise do anythign, > (like tell a web browser user they need a certain

RE: Eval for module

2003-08-07 Thread Dan Muey
> > That's because eval BLOCK still compiles the block at > compile-time. You want to use eval EXPR. > > eval 'use Module ...; 1'; > if ($@) { uh oh } > > You can also use q{} instead of single quotes for more > code-like appearance. Excellent Jeff! Thanks for that tid bit I missed it so

Re: Eval for module

2003-08-06 Thread Jeff 'japhy' Pinyan
On Aug 6, Dan Muey said: >Whenever I've tried to do: > > eval { use module; }; > if($@) . > >It always fails and I can't trap it it to , say, try a different module >if it's not found or otherwise do anythign, (like tell a web browser user >they need a certain module for it to work: Tha