in reply to Re^7: Understanding the benefit of Given/When ...
in thread Understanding the benefit of Given/When ...

What I meant was that phrase in the docs to for/when:

On exit from the when  block, there is an implicit next.

so you can use a simple if where you wanted to write  when () { ...; continue} and vice versa you can write when where you wanted to write if () {...; next} ! (as long you don't need the implicit smart match)

In other words: This next in your code

... say " After when /abc/"; when (/def/) {say " Got 'def'"; next;} say " After when /def/"; ...
is a tautology...

Cheers Rolf

Replies are listed 'Best First'.
Re^9: Understanding the benefit of Given/When ...
by JavaFan (Canon) on Mar 04, 2010 at 17:48 UTC
    Yes, showing there was no difference between having and not having a trailing 'next' was the reason for including that when block.