Perl6 RFC Librarian writes:
> An inconsistency between "C<print>" and "<>" bugs me: "C<print;>" means
> "C<print $_;>" so it seems like "<>" should mean "C<$_ = > <>".
> I can't yet think of code that this extension would break.
I assume you mean that <> in void context should assign to $_?
Any code that has set $_, then uses
<FH>;
to skip the next line, will have inadvertently trashed $_.
However, the perl526 translator can fix it by replcing void-context
<FH> with
{ local $_; <FH>; }
Nat
- RFC 215 (v1) More defaulting to C<$_>. Perl6 RFC Librarian
- Re: RFC 215 (v1) More defaulting to C<$_>. Philip Newton
- Re: RFC 215 (v1) More defaulting to C<$_>. John Porter
- Re: RFC 215 (v1) More defaulting to C<$_>. Nathan Wiger
- Nathan Torkington
