Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68503 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 93824 invoked from network); 14 Aug 2013 06:30:08 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 14 Aug 2013 06:30:08 -0000 Authentication-Results: pb1.pair.com header.from=bof@bof.de; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=bof@bof.de; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain bof.de designates 80.242.145.70 as permitted sender) X-PHP-List-Original-Sender: bof@bof.de X-Host-Fingerprint: 80.242.145.70 mars.intermailgate.com Received: from [80.242.145.70] ([80.242.145.70:35424] helo=mars.intermailgate.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 5D/7E-06453-EE32B025 for ; Wed, 14 Aug 2013 02:30:07 -0400 Received: (qmail 11158 invoked by uid 1009); 14 Aug 2013 08:30:02 +0200 Received: from 209.85.128.174 by mars (envelope-from , uid 89) with qmail-scanner-1.25-st-qms (clamdscan: 0.96.2/17676. spamassassin: 3.3.1. perlscan: 1.25-st-qms. Clear:RC:1(209.85.128.174):. Processed in 0.068834 secs); 14 Aug 2013 06:30:02 -0000 X-Antivirus-MYDOMAIN-Mail-From: bof@bof.de via mars X-Antivirus-MYDOMAIN: 1.25-st-qms (Clear:RC:1(209.85.128.174):. Processed in 0.068834 secs Process 11152) Received: from mail-ve0-f174.google.com (gmail@bof.de@209.85.128.174) by mars.intermailgate.com with RC4-SHA encrypted SMTP; 14 Aug 2013 08:30:02 +0200 Received: by mail-ve0-f174.google.com with SMTP id d10so7389588vea.19 for ; Tue, 13 Aug 2013 23:30:00 -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 :content-type; bh=8M1t7Jh+s9vfAPxYXjZ5h/V1U4rJo1JpzSCAlemavDg=; b=hmf9wuYMUYROh87eSkF59UnC8KIxuoTDMjcCmsHEm4ujEYw6IW0g81K5KwlUuSwtg8 cyJin9t/Oz92QwYxLa1/Uyt6rQ8jcwcNTz3AuYX5fMZrK5a63oBcrdqTrJ01xi+RspQF fRyCDQ/cxMqZxqIeyjX0vchHGNQ6cjwGqeInwy2hP1iNh9F2zOUmUt+76w3N7nICXGgJ vwGuqA9pRY1MWVZGF2/jTbBrpoE76+/G3n/hZvrxelVl1dlQzA/I0WjNM53Zv+tytIR1 XL34QTJA7jdt7oqmSqhlx3PjG6DSU1XKlmuF/QbjFTePHQ7jTg17eoRYLPpE40ir+6oK oqjQ== MIME-Version: 1.0 X-Received: by 10.52.35.98 with SMTP id g2mr6872346vdj.0.1376461800162; Tue, 13 Aug 2013 23:30:00 -0700 (PDT) Received: by 10.52.240.49 with HTTP; Tue, 13 Aug 2013 23:30:00 -0700 (PDT) Received: by 10.52.240.49 with HTTP; Tue, 13 Aug 2013 23:30:00 -0700 (PDT) In-Reply-To: References: <4ED7146272E04A47B986ED49E771E347BB514EEE88@Ikarus.ameusgmbh.intern> Date: Wed, 14 Aug 2013 08:30:00 +0200 Message-ID: To: internals Content-Type: multipart/alternative; boundary=20cf307f3bfaa5788604e3e27c4e Subject: RE: [PHP-DEV] [RFC] Constant Scalar Expressions From: bof@bof.de (Patrick Schaaf) --20cf307f3bfaa5788604e3e27c4e Content-Type: text/plain; charset=ISO-8859-1 Would this allow using constants, too? Class constants? const FOO = 1; const BAR = self::FOO + 1; const BAZ = self::FOO + 2; const BARF = GLOBAL_BARF; const IMPORT = otherclass::IMPORT; // with autoloading? In my opinion these would start to make the feature useful. Even more useful, but probably outside the scope of that RFC, would be permitting arbitrary expressions in the initializers (const or property defaults) that would be resolved at runtime, before the class is used for the first time. best regards Patri --20cf307f3bfaa5788604e3e27c4e--