Re: line numbers with Filter::Simple

2007-06-01 Thread Rocco Caputo
On May 30, 2007, at 16:38, David Nicol wrote: We can declare a line number, in source code, like so # perl foo #line 54 die smiling foo smiling at - line 54. # and counting newlines within a Filter::Simple code block is easy enough but how do I find out what line to start at, so I can

Re: line numbers with Filter::Simple

2007-06-01 Thread David Nicol
On 6/1/07, Rocco Caputo [EMAIL PROTECTED] wrote: caller() is a good solution. I use it, Filter::Util::Call, and some involved #line magic to maintain sane line numbers in Filter::Template. I am preprocessing the code to add line number identifiers between all lines, then when I process the