in reply to Re^2: Syntax question about closures and Perl 'sort'
in thread Syntax question about closures and Perl 'sort'
"isn't really a closure.."
Exactly, even though it technically is a real closure. The unnamed sub will remember the value of $type as long as the sub exists (in that sense it is a closure). But since $type isn't used anywhere in the unnamed sub, it is of no consequence.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Syntax question about closures and Perl 'sort'
by tilly (Archbishop) on Apr 04, 2009 at 04:41 UTC | |
by jethro (Monsignor) on Apr 05, 2009 at 18:43 UTC |