Thank you, this is useful!
Two questions.. One on topic and one off topic.
Why not..my $start_with = another_value() or ( warn("Could not get another value"), return );
Or evenmy $start_with = another_value() or warn("Could not get another value"), return;
I tried these out and they seem to work fine. I suppose it's maybe trying to mess with the compiler/interpreter being vague with arguments to warn(), in the last example.my $start_with = another_value() or warn "Could not get another value", return;
Are you using parenthesis as good practice/legibility only?
It seems that unless I want to create my own perl distro, there's no way to do as JavaFan suggests ( 779943 ).
Perl's pretty freaking liberal with what it lets you do with symbol tables, but.. we can't just add another function to the language at compile time.
I wonder if this is something lisp could do- probably not- this must be on the language design (compiler/interpreter) level, not the coding level (?).
( Actually, as Corion noted initially.. 779928 )
In reply to Re^2: how to write a modified return() call?
by leocharre
in thread how to write a modified return() call?
by leocharre
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |