in reply to Printing the result of calling an instance method
Subroutine calls don't interpolate in strings unless you do a bit of particularly kludgy magic. Try this:
print qq(<TD>@{[$obj->attr1()]}</TD>\n);
Very nasty. But it works :)
--
"Perl makes the fun jobs fun
and the boring jobs bearable" - me
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re (tilly) 2: Printing the result of calling an instance method
by tilly (Archbishop) on Apr 02, 2001 at 13:27 UTC | |
by davorg (Chancellor) on Apr 02, 2001 at 13:33 UTC | |
|
Re: Re: Printing the result of calling an instance method
by ColtsFoot (Chaplain) on Apr 02, 2001 at 12:47 UTC |