Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:14281 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 36198 invoked by uid 1010); 4 Jan 2005 23:58:06 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 36163 invoked from network); 4 Jan 2005 23:58:05 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Jan 2005 23:58:05 -0000 X-Host-Fingerprint: 217.148.166.184 conan.ard.nu Linux 2.4/2.6 Received: from ([217.148.166.184:39875] helo=conan.ard.nu) by pb1.pair.com (ecelerity HEAD (r3992M)) with SMTP id 52/C6-06279-B8D2BD14 for ; Tue, 04 Jan 2005 18:58:03 -0500 Received: from localhost ([127.0.0.1]) by conan.ard.nu with esmtp (Exim 4.34) id 1ClyYo-00082q-IF for internals@lists.php.net; Wed, 05 Jan 2005 00:57:58 +0100 Message-ID: <41DB2D85.1080700@iamjochem.com> Date: Wed, 05 Jan 2005 00:57:57 +0100 User-Agent: Mozilla Thunderbird 0.9 (Windows/20041103) X-Accept-Language: en-us, en MIME-Version: 1.0 To: php internals Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: CONSTANT names... From: jochem@iamjochem.com (Jochem Maas) hi guys, I was mucking around and noticed the following: define("404_SKIP", 1); does not give an error and you can successfully get the value of the constant by doing: constant("404_SKIP"); where as doing: echo 404_SKIP; gives an error. as I understand it, i.e. what the docs say, is that the following regexp expresses valid starting chars for the name of a constant (the same going for vars): /^[a-zA-Z_\x7f-\xff]/ so pretty minor thing here but I expected to see the define() throw a (fatal?) error, rather than letting me go on. kind regards, Jochem