Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:61472 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 46937 invoked from network); 19 Jul 2012 10:06:38 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Jul 2012 10:06:38 -0000 Authentication-Results: pb1.pair.com header.from=listas@rafaeldohms.com.br; sender-id=fail Authentication-Results: pb1.pair.com smtp.mail=listas@rafaeldohms.com.br; spf=fail; sender-id=fail Received-SPF: fail (pb1.pair.com: domain rafaeldohms.com.br does not designate 209.85.220.170 as permitted sender) X-PHP-List-Original-Sender: listas@rafaeldohms.com.br X-Host-Fingerprint: 209.85.220.170 mail-vc0-f170.google.com Received: from [209.85.220.170] ([209.85.220.170:46004] helo=mail-vc0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 25/34-25752-D2CD7005 for ; Thu, 19 Jul 2012 06:06:38 -0400 Received: by vcbgb30 with SMTP id gb30so1128966vcb.29 for ; Thu, 19 Jul 2012 03:06:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:x-gm-message-state; bh=wIk3J1cfKNN9viEtMzbkAF6n3Xwo8xzgpV2QbsLlxl4=; b=VlJTpDwmukZTMHPiDXZkTPhiorBykuuzTmFGu50hm0BzDHcNdC42oKBV1ptAlX2gca YV14eMUoSG+6W9Fb856AXos88DLdAUddVnhE5qiqbw0dLYtrjRVtLl8TyWcBiE3W9T97 K7eP430Nxzf17wiscD5Y6TqzW8OplOTryuqxz3cnCAP9tl9LlF7ucE8DhGdLyRWWIqn+ jV3akiNW+2ub8nlcxi5XPdGnuNQ5UbskSTox6qkFPdCLAdcNAc+wBQGVjm+IPFNdkeOA 2gnfHSTVPi8ux+LxFcGFhggUTvalYC+T0NOEHEveiPmHEfa2/jlMw3sYYM+Pogi/cGaf hrOw== MIME-Version: 1.0 Received: by 10.220.225.194 with SMTP id it2mr622686vcb.32.1342692394824; Thu, 19 Jul 2012 03:06:34 -0700 (PDT) Received: by 10.220.46.13 with HTTP; Thu, 19 Jul 2012 03:06:34 -0700 (PDT) In-Reply-To: <095CAA408DA94AFB9E75C12877A9043D@charliesomerville.com> References: <5007D707.2070100@hoa-project.net> <095CAA408DA94AFB9E75C12877A9043D@charliesomerville.com> Date: Thu, 19 Jul 2012 12:06:34 +0200 Message-ID: To: Charlie Somerville Cc: ivan.enderlin@hoa-project.net, internals@lists.php.net Content-Type: multipart/alternative; boundary=14dae9ccd5103c751b04c52bef94 X-Gm-Message-State: ALoCoQki8Sv2bggRUAji1Pirka8QhGkCfJtUS85feqYStxnym1Vw5EVUmZq5J+etK5iTKMsYcb/L Subject: Re: [PHP-DEV] Make try/catch brackets optinal From: listas@rafaeldohms.com.br (Rafael Dohms) --14dae9ccd5103c751b04c52bef94 Content-Type: text/plain; charset=ISO-8859-1 On Thu, Jul 19, 2012 at 12:03 PM, Charlie Somerville < charlie@charliesomerville.com> wrote: > This has code readability problem written all over it. When maintaining it > also has problems, like with the bracket-less if's. > You would need to add brackets if you add an extra line here, as well as > you might get unexpected behaviour of you forget to > add brackets in that case. > > I've often heard people make this argument, but I've never found it to be > a real concern in practise. > > Is this really such a common problem? > I have seen this problem happen, people losing time trying to figure out what is wrong only to find its a missing bracket. As Paul said, this is bug-prone. -- Rafael Dohms PHP Evangelist and Community Leader http://www.rafaeldohms.com.br http://www.phpsp.org.br --14dae9ccd5103c751b04c52bef94--