On Fri, Mar 18, 2011 at 5:23 PM, Uri Guttman <u...@stemsystems.com> wrote:
> >>>>> "sw" == shawn wilson <ag4ve...@gmail.com> writes: > > please learn how to quote emails properly. it is hard to tell here what > i replied and what you wrote. > > sorry, i don't know how to do any better in gmail (and does it different on the gmail app on my android too - sorta messed up). should i color replies differently or something? > >> > >> so, what your saying is: > sw> my $writer = sub { > sw> my $a = shift; > sw> return [ 200, [ "Content-type" => "text/plain" ], $s ]; > sw> } > > no. where is the use of $a? where is the code call that dereferences the > ref? > > here's the whole function (i didn't think i needed to post it because i get the rest of this code): my $s = Streamer->new; my $app = sub { return sub { $s->open_fh; my $writer = shift->( [ 200, [ "Content-type" => "text/plain" ], $s ] ); }; };