http://www.perlmonks.org?node_id=978155


in reply to How to use empty "<>" (Diamond Operator) inside While loop

No, that is not how the diamond operator works. It checks for arguments, but only to treat them as file names. If there are no arguments, it reads its input from STDIN. You can try that with
echo This is the standard input | perl diamond.pl
See I/O Operators

Replies are listed 'Best First'.
Re^2: How to use empty "<>" (Diamond Operator) inside While loop
by zwon (Abbot) on Jun 25, 2012 at 13:08 UTC