in reply to File-scoped lexicals and eval scope?

'ex' ne 'example'

Are you sure you are calling the sub that you think you are calling?

Update: Now I actually tested the code (and not just looked at it), and all I get is this message (with perl 5.8.8):

Can't use string ("") as a subroutine ref while "strict refs" in use at driver.pl line 4, <DATA> line 1.</c>

Are you sure that you get a newline as output if you run exactly that script?

Replies are listed 'Best First'.
Re^2: File-scoped lexicals and eval scope?
by Cambo (Initiate) on Nov 09, 2007 at 17:15 UTC
    Yeah, I ended up with a typo in what I posted, when I was trying to clean it up for public consumption. Obviously, running the code I posted would blow up. It probably doesn't do any good asking for help on this sort of problem when my example doesn't run. I'll try to be more pedantic next time :) Cambo