in reply to Re: looking for a good idiom: return this if this is true
in thread looking for a good idiom: return this if this is true
Doesn't the following bit of code work? It's only slightly more obtuse than what you propose.
UPDATE AGAIN: Ah, I missed the point. My code does not return the value returned by thatroutine(). If there are no side effects I suppose you could do:
----
My mission: To boldy split infinitives that have never been split before!
UPDATE: I just tested this to prevent ignorance, and it does in fact work.thatroutine() and return 1;
UPDATE AGAIN: Ah, I missed the point. My code does not return the value returned by thatroutine(). If there are no side effects I suppose you could do:
:-)thatroutine() and return thatroutine();
----
My mission: To boldy split infinitives that have never been split before!
In Section
Seekers of Perl Wisdom