in reply to Re^2: Use global flag when declaring regular expressions with qr?
in thread Use global flag when declaring regular expressions with qr?

while ( <> ) already defaults to STDIN.
$ t() { perl -Mv5.10 -e'while (<>) { chomp; say "<$_>"; }' "$@"; } $ t \ <( echo 'Contents of virtual file 1' ) \ <( echo 'Contents of virtual file 2' ) <Contents of virtual file 1> <Contents of virtual file 2> $ echo 'Contents of virtual file' | t <Contents of virtual file>

Replies are listed 'Best First'.
Re^4: Use global flag when declaring regular expressions with qr?
by unmatched (Sexton) on Oct 28, 2024 at 23:01 UTC

    Clearly, I still have a lot to learn. I'll go have a read on all the basics a little more before I continue with this I think.

    Thank you again!