Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:82344 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 31529 invoked from network); 10 Feb 2015 07:31:28 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 10 Feb 2015 07:31:28 -0000 Authentication-Results: pb1.pair.com smtp.mail=pthreads@pthreads.org; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=pthreads@pthreads.org; sender-id=unknown Received-SPF: error (pb1.pair.com: domain pthreads.org from 209.85.192.169 cause and error) X-PHP-List-Original-Sender: pthreads@pthreads.org X-Host-Fingerprint: 209.85.192.169 mail-pd0-f169.google.com Received: from [209.85.192.169] ([209.85.192.169:33454] helo=mail-pd0-f169.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 97/AA-47508-FC3B9D45 for ; Tue, 10 Feb 2015 02:31:27 -0500 Received: by pdbnh10 with SMTP id nh10so34684823pdb.0 for ; Mon, 09 Feb 2015 23:31:24 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=iBB9/HAur/UG+w0RjwxmQyrHBiWkFId5XWeeB5wfqR4=; b=h/RUnd88iw2V7nTqDT3JvE8uSWDzguYb2NfUYu8D0xO2Gh1hF4WD8iDLEjGlqqJzqG S7c/pWJxQJWORbSXDROISA0/k5eLL9g2d7Dz2bebksi/9EO7Yo2twOmbQyDz34DPUbks m9cqzemwaVyYqEPULz2PKjBkbahug4EWDj9pMGuW0/Kx9p9ot4WP0GUSAGxoDrlKeDCR HA5lAMnTpTGSEZBRDfH5pb0exqpl0e8ewBtSAqqteN4UdbmgP9xJLUWgkqNLQbFbdoxz MirMoyYEEjm99k7h8O4WZMZLkscnq7u4djKYRUDMG7TJeSgPxGMdd6k7YGePnLb54Q35 VOAw== X-Gm-Message-State: ALoCoQnyWRIssAWGLxmaSbPb8vs82ueUJhdk+i8g527SpQOGYSy+NJtl8AWKzO3CWpudtl96Brvd MIME-Version: 1.0 X-Received: by 10.68.134.164 with SMTP id pl4mr35120105pbb.128.1423553484796; Mon, 09 Feb 2015 23:31:24 -0800 (PST) Received: by 10.70.49.100 with HTTP; Mon, 9 Feb 2015 23:31:24 -0800 (PST) X-Originating-IP: [109.145.22.92] In-Reply-To: References: <54D7ED22.3080001@gmail.com> Date: Tue, 10 Feb 2015 07:31:24 +0000 Message-ID: To: Yasuo Ohgaki Cc: Dmitry Stogov , Patrick Schaaf , internals Content-Type: multipart/alternative; boundary=047d7b10cb03c7ce0e050eb6df8f Subject: Re: [PHP-DEV] Design by Contract From: pthreads@pthreads.org (Joe Watkins) --047d7b10cb03c7ce0e050eb6df8f Content-Type: text/plain; charset=UTF-8 Actually I'm not sure it's at all sane to try to override contracts, I'd actually avoid that completely, so no need to name contracts and no need for magic __invariant. Cheers Joe On Tue, Feb 10, 2015 at 7:26 AM, Yasuo Ohgaki wrote: > Hi Dmitry, > > On Tue, Feb 10, 2015 at 4:21 PM, Dmitry Stogov wrote: > > > 4) regarding the error message second argument to the condition > >> definitions, it would be useful to have these not only as plain > >> (extrapolated) strings, but as full expressions-that-evaluate-to-string. > >> That would permit hooking to arbitrary private logging and log > formatting > >> methods. > >> > > I don't think we will implement this. It may be proposed later as a DbC > > extension. > > > > I thought it works just like assert(), but no problem for me. > > > > 5) and a bit off-topic, it would be useful to be able to declare (sic) > >> whole methods to be nonproduction only: Methods that will only be used > in > >> pre/post/invariant condition expresions (or error formatters a la my > point > >> 4) > >> > > this is also not directly related as well. > > Sorry, but we should define realistic target to be able to provide a > > working solution. > > We can't think about all possible and indirectly related features at > once. > > > > I agree. > > Regards, > > -- > Yasuo Ohgaki > yohgaki@ohgaki.net > --047d7b10cb03c7ce0e050eb6df8f--