Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68508 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 12016 invoked from network); 14 Aug 2013 09:12:16 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 14 Aug 2013 09:12:16 -0000 Authentication-Results: pb1.pair.com smtp.mail=patrick.allaert@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=patrick.allaert@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.219.51 as permitted sender) X-PHP-List-Original-Sender: patrick.allaert@gmail.com X-Host-Fingerprint: 209.85.219.51 mail-oa0-f51.google.com Received: from [209.85.219.51] ([209.85.219.51:33863] helo=mail-oa0-f51.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 3F/71-06453-FE94B025 for ; Wed, 14 Aug 2013 05:12:16 -0400 Received: by mail-oa0-f51.google.com with SMTP id h1so12757967oag.38 for ; Wed, 14 Aug 2013 02:12:13 -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:date:message-id:subject :from:to:cc:content-type; bh=ktOBWqcqGsUYsgLvO+XDlMy1SnCybw/v5nYfWKeJMs4=; b=clnMAZ4YUhSgm+k4PCRQA5d0WzpSQOoc8pj2k6y7PhFZks0X3nF21X4/5HQycMhlWl 0qxPAuLA3gl8HtXtjrdhMVUvQws0hgb1M0MmOGww2U/SH46yYEIaJUfwBrFLCDFWS8bC NO2dJTh4NhaeWpMbKWPIhcV5cpbIPLM2ues/QBZjxIn2a2RA8xyR2nbgrZnS4f+Pvj6L 1Fne/JKDqIXFN3e8UtQ4+Xk6VlXL81r8fGdunlkPSdIDkHDGp8AW4afkZPatKkOTsQrt 8LlbUNiiDRDlFLXH+2bNZZWZF5JnVdkvI2jX7qEtMBt8DvNls08fhp6Ygs74jYPK7a6N bNYA== MIME-Version: 1.0 X-Received: by 10.182.112.166 with SMTP id ir6mr19773346obb.25.1376471533342; Wed, 14 Aug 2013 02:12:13 -0700 (PDT) Sender: patrick.allaert@gmail.com Received: by 10.76.173.34 with HTTP; Wed, 14 Aug 2013 02:12:13 -0700 (PDT) In-Reply-To: References: Date: Wed, 14 Aug 2013 11:12:13 +0200 X-Google-Sender-Auth: 8mv3M5TY0Owlo41aOT8XVdvbSZM Message-ID: To: Anthony Ferrara Cc: "internals@lists.php.net" Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] [RFC] Constant Scalar Expressions From: patrickallaert@php.net (Patrick ALLAERT) 2013/8/13 Anthony Ferrara : > Hello all, > > I'd like to propose a new RFC for 5.NEXT: > > https://wiki.php.net/rfc/const_scalar_expressions > > This allows for defining constant expressions which are resolved at compile > time. > > for example: > > const FOO = 1 + 1; > static $bar = 1 << 2; > function foo($a = 1 | 2) {} > class foo { > public $bar = 1 << 2; > } > > Thoughts? > > Anthony Since the RFC specifically avoid the possibility to use non static values: +1 Cheers, Patrick -- Patrick Allaert --- http://code.google.com/p/peclapm/ - Alternative PHP Monitor