Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68187 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 71915 invoked from network); 19 Jul 2013 09:00:20 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Jul 2013 09:00:20 -0000 Authentication-Results: pb1.pair.com smtp.mail=yohgaki@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=yohgaki@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.217.177 as permitted sender) X-PHP-List-Original-Sender: yohgaki@gmail.com X-Host-Fingerprint: 209.85.217.177 mail-lb0-f177.google.com Received: from [209.85.217.177] ([209.85.217.177:60791] helo=mail-lb0-f177.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id D9/00-05704-12009E15 for ; Fri, 19 Jul 2013 05:00:17 -0400 Received: by mail-lb0-f177.google.com with SMTP id 10so3205429lbf.22 for ; Fri, 19 Jul 2013 02:00:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=5uInUGIY5ysR+szYhGpg/j6TEZltEz4oH2mC7MtVXRc=; b=mvZKsxyN93aS2+dMm51TTetrjDwcVoV98Uiu1f6k+FIwGqgI+XrMJ6Lmbfd46iOx/2 elQbss4nmFyqZLvPbY8StsYNv+5TxIfR+HdLXtfUpC08bTt1zB4/nCDKxba6pvAurp8s BeDmI8m7EOdujLbfLtsHj7myLATOn3QVFJ+R1Zkp9nnXi7MM1VU8MHIv2ROe2eD35WsR HeeTBZ+G4semNEUxJq6UWlLqdGPTsQqtpI6SJXn/LkD1ZrG0Y04/jBOI7jGmgEMyC0v/ j1NVy4GR4/yPkVfmtIsmSRU1dlKzEBd8mpr90vCsE+jjpzZssAclFiL+K/AmkYiK/YbA mYtg== X-Received: by 10.112.219.102 with SMTP id pn6mr6994423lbc.18.1374224414279; Fri, 19 Jul 2013 02:00:14 -0700 (PDT) MIME-Version: 1.0 Sender: yohgaki@gmail.com Received: by 10.112.4.233 with HTTP; Fri, 19 Jul 2013 01:59:34 -0700 (PDT) In-Reply-To: References: <-6008161650538629327@unknownmsgid> Date: Fri, 19 Jul 2013 17:59:34 +0900 X-Google-Sender-Auth: aBpumhT0XqERR6TP6q-vddFAz7U Message-ID: To: Peter Lind Cc: Mateusz Kocielski , Xinchen Hui , Chris London , "internals@lists.php.net" Content-Type: multipart/alternative; boundary=001a11c3ca140e0f8804e1d98e1c Subject: Re: [PHP-DEV] Feature Proposal: Allow letter decrementing From: yohgaki@ohgaki.net (Yasuo Ohgaki) --001a11c3ca140e0f8804e1d98e1c Content-Type: text/plain; charset=ISO-8859-1 Hi, I take a look at the code. It does support [0-9] also. [yohgaki@dev tests]$ php -r "\$a = ' a10';for (\$i=0; \$i<10;\$i++) var_dump(++\$a);" string(4) " a11" string(4) " a12" string(4) " a13" string(4) " a14" string(4) " a15" string(4) " a16" string(4) " a17" string(4) " a18" string(4) " a19" string(4) " a20" It sounds good to have string decrements. 2013/7/19 Peter Lind > Interesting to note that although Perl 6 is apparently capable of > decrementing strings, it doesn't fully mirror the incrementing: > > http://feather.perl6.nl/syn/S03.html#line_516 > > Specifically: decrementing 'AAA' would not turn into 'ZZ' but would error, > according to that link > Carry handle of decrements is more complex than increments. It may be the reason. Regards, -- Yasuo Ohgaki yohgaki@ohgaki.net --001a11c3ca140e0f8804e1d98e1c--