I think you are really creating a label named return here, followed by a constant expression. As that expression is the last expression evaluated, it is used as return value.
Look at this code: It returns 5 and gives a "Useless use of a constant in void context" warning:
sub foo { return: 3; return 5; }
Alexander
In reply to Re: 'return:' instead of 'return'
by afoken
in thread 'return:' instead of 'return'
by Boldra
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |