in reply to subroutine inside subroutine
by adding a ';' after use strict. The error message is a bit misleading.
PS: Please use warnings as well. And you know that a subroutine inside another subroutine in perl is a closure? It might not always do what you expect from it (if you export a reference to it outside the enclosing subroutine).
Updated: Reworded the warning about closure
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: subroutine inside subroutine
by Your Mother (Archbishop) on Jul 02, 2010 at 19:59 UTC |