From: Randal L. Schwartz Date: Fri, 30 May 2008 21:44:27 GMT Subject: Re: [PATCH] perl/Git.pm: add parse_rev method Message-ID: <86r6bjmpqc.fsf@blue.stonehenge.com> In-Reply-To: <7vd4n3iivt.fsf@gitster.siamese.dyndns.org> >>>>> "Junio" == Junio C Hamano writes: Junio> Perhaps, but except for the use of nonstandard try...catch. I have been Junio> wondering if we can move away from it, with the goal of eventually getting Junio> rid of the construct altogether. Junio> Didn't we hear from Randal that the construct is known to be leaky? It'd be trivial to avoid this try/catch. eval { ... }; if ($@) { if (UNIVERSAL::isa($@, "That::Class::Which::Should::Be::Ignored")) { # ignore it } else { die $@; # re-throw it } } No leak there. -- Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095 Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc. See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion