Closed leonerd closed 1 year ago
This grammar makes several distinctions between for and foreach. The real perl parser considers them as exact synonyms of each other. Any and all syntax forms that are accepted by one are accepted by the other. Yes; even C-style for loops:
for
foreach
$ perl -E 'foreach(my $i = 0; $i < 3; $i++) { say $i }' 0 1 2
(I can send a PR to fix this)
This is integrated with #27 so this issue can be closed
This grammar makes several distinctions between
for
andforeach
. The real perl parser considers them as exact synonyms of each other. Any and all syntax forms that are accepted by one are accepted by the other. Yes; even C-stylefor
loops:(I can send a PR to fix this)