Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:67168 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 9490 invoked from network); 26 Apr 2013 14:46:08 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 26 Apr 2013 14:46:08 -0000 Authentication-Results: pb1.pair.com smtp.mail=syragg@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=syragg@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.210.171 as permitted sender) X-PHP-List-Original-Sender: syragg@gmail.com X-Host-Fingerprint: 209.85.210.171 mail-ia0-f171.google.com Received: from [209.85.210.171] ([209.85.210.171:35079] helo=mail-ia0-f171.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 62/24-15719-0339A715 for ; Fri, 26 Apr 2013 10:46:08 -0400 Received: by mail-ia0-f171.google.com with SMTP id r13so3633150iar.16 for ; Fri, 26 Apr 2013 07:46:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=ZNoW689C1miXaDQDevApfefz0Q4DlRqeWvpsGcZ6go0=; b=i+GdLzfvPEQl18esBc5W2ggT/AaQ+4djjCQ6CwVLePsjyomxJbs234tGCN9tnR3zt/ 9RDu9fZzHK9lUPuJOFx5Eqy2G0CUSgJhB3IqS9TxdZ6KL0jsbxmvCiBx9HyYlMg/UyTZ uXP0hDp1+profDKfsefyGFAcV7xtRc8A20rl+poz9dGVoqS2K8jwesNFsePCN1vVKg+7 gBqSvNozu56n8nBDoBXWM/NXEczaNFvqiitQHTIbLok+4+HRZDkra0U80OmSuatitATG wv4MO7KnMTyjY41piCWARqP619fBioi9rA7l+Zyu7YscNJB6SOKnYTSe+gT0tX75Yyng SFiQ== MIME-Version: 1.0 X-Received: by 10.50.60.102 with SMTP id g6mr2008749igr.112.1366987565766; Fri, 26 Apr 2013 07:46:05 -0700 (PDT) Received: by 10.50.192.196 with HTTP; Fri, 26 Apr 2013 07:46:05 -0700 (PDT) In-Reply-To: References: Date: Fri, 26 Apr 2013 21:46:05 +0700 Message-ID: To: Julien Pauli Cc: internals@lists.php.net Content-Type: multipart/alternative; boundary=047d7b10c989451f1604db4498c2 Subject: Re: [PHP-DEV] Continued try blocks From: syragg@gmail.com (=?KOI8-R?B?4czFy9PBzsTSIOLPwtLP1w==?=) --047d7b10c989451f1604db4498c2 Content-Type: text/plain; charset=ISO-8859-1 Sounds interesting. And what about the second attempt passing the try block without goto? 2013/4/26 Julien Pauli > Hello internals, > > I had an idea recently with a friend, about a feature try-catch blocks > could use. > Let me just write an example, you will quickly understand the idea : > > * * > * > *try {* > * foo();* > * bar();* > * baz();* > *} catch (SomeException $e) {* > * dosomestuff();* > * continue; /* Here is the feature, go back to try block */* > *} catch (Exception $e) {* > * dosomething();* > *}* > > > > The continue keyword would resume the execution from where it had > diverged, according to the function which led to the SomeException > catch block. > > So, in this example, if, say, bar() throws a SomeException , the code > would then resume and execute baz() after the catch block. > > Just presenting the idea here, no RFC actually , I'm collecting > thoughts and notices. > > Julien.Pauli > --047d7b10c989451f1604db4498c2--