Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:67181 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 81683 invoked from network); 27 Apr 2013 13:57:20 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 27 Apr 2013 13:57:20 -0000 Authentication-Results: pb1.pair.com smtp.mail=amaury.bouchard@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=amaury.bouchard@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.216.179 as permitted sender) X-PHP-List-Original-Sender: amaury.bouchard@gmail.com X-Host-Fingerprint: 209.85.216.179 mail-qc0-f179.google.com Received: from [209.85.216.179] ([209.85.216.179:44888] helo=mail-qc0-f179.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id D7/61-08285-F39DB715 for ; Sat, 27 Apr 2013 09:57:19 -0400 Received: by mail-qc0-f179.google.com with SMTP id v28so2454122qcm.10 for ; Sat, 27 Apr 2013 06:57:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=Xx76CzG3K7faPKXN5s+m03+HGkJ/L28rkL2kGMdgLo4=; b=VR8HFjpaVf76jNTX0QrkCJxSefLBB9zBkcr/ZdQ+QHsmWAqT4bdKC3Pzx5wkuCRBcp 2S3H7ymUDHAvXW2KTOpzxmJW34HmDFcKLA2nfjRlRPpMRdeb+zWk1d+cB4/gFq3Py3BL XiQZvs9/sSKtd/HB+eqhqOJ9rNFGYhr4wKqbEerZibNFqEVnZWAsfA7EOy1GoQLw2/LL wUZjvDtL4mva2/OhCT1+EK/SVSc2PpVwHCIIinvKM5M4pznkCTK97j5B/A+7+lMdz4Nc GzZHw2w9AgQi1xRspp6tIGKeGxxz5R16I+G4/+eUHssihxSBNyW4bW9mSdsC/tNPRuWM HDLQ== X-Received: by 10.224.136.132 with SMTP id r4mr45144407qat.93.1367071036662; Sat, 27 Apr 2013 06:57:16 -0700 (PDT) MIME-Version: 1.0 Sender: amaury.bouchard@gmail.com Received: by 10.49.133.39 with HTTP; Sat, 27 Apr 2013 06:56:56 -0700 (PDT) In-Reply-To: References: <170891005.EmXIrsICLC@rofl> Date: Sat, 27 Apr 2013 15:56:56 +0200 X-Google-Sender-Auth: zYrmlqXZA66-wOBUQ7CcRUK_Jgg Message-ID: To: Ferenc Kovacs Cc: Julien Pauli , PHP Internals , Patrick Schaaf Content-Type: multipart/alternative; boundary=001a11c2b89c863ce604db580771 Subject: Re: [PHP-DEV] Continued try blocks From: amaury@amaury.net (Amaury Bouchard) --001a11c2b89c863ce604db580771 Content-Type: text/plain; charset=ISO-8859-1 2013/4/27 Ferenc Kovacs > please don't reuse the continue keyword for it. > > There are a bunch of code out there where which uses exceptions in a loop > context. > For example you have a retry counter decremented in a loop and you catch > the exceptions and retry until the retry limit is reached. > Fair enough. We can use "resume". try { doThis(); doThat(); } catch (NotImportantException $nie) { addToLog($nie->getMessage()); resume; } catch (Exception $e) { cleanupEverything(); } --001a11c2b89c863ce604db580771--