Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:84185 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 86915 invoked from network); 2 Mar 2015 21:20:25 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 2 Mar 2015 21:20:25 -0000 Authentication-Results: pb1.pair.com header.from=php@tutteli.ch; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=php@tutteli.ch; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain tutteli.ch designates 80.74.154.78 as permitted sender) X-PHP-List-Original-Sender: php@tutteli.ch X-Host-Fingerprint: 80.74.154.78 ns73.kreativmedia.ch Linux 2.6 Received: from [80.74.154.78] ([80.74.154.78:60707] helo=hyperion.kreativmedia.ch) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DE/9C-14834-514D4F45 for ; Mon, 02 Mar 2015 16:20:22 -0500 Received: (qmail 25436 invoked from network); 2 Mar 2015 22:20:16 +0100 Received: from cm56-153-252.liwest.at (HELO RoLaptop) (86.56.153.252) by ns73.kreativmedia.ch with ESMTPSA (AES256-SHA encrypted, authenticated); 2 Mar 2015 22:20:16 +0100 To: "'Julien Pauli'" , "'Dmitry Stogov'" Cc: "'Alexander Lisachenko'" , "'PHP internals list'" References: In-Reply-To: Date: Mon, 2 Mar 2015 22:20:15 +0100 Message-ID: <009d01d0552e$ae2c4da0$0a84e8e0$@tutteli.ch> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQIPk8nXQdC7YxKTesF5vliHaD2pywEe37LPAYZ/+u6cdgploA== Content-Language: de-ch Subject: AW: [PHP-DEV] [Discussion] Last chance for case-sensitive engine From: php@tutteli.ch ("Robert Stoll") > -----Urspr=C3=BCngliche Nachricht----- > Von: julienpauli@gmail.com [mailto:julienpauli@gmail.com] Im Auftrag = von Julien Pauli > Gesendet: Donnerstag, 26. Februar 2015 10:27 > An: Dmitry Stogov > Cc: Alexander Lisachenko; PHP internals list > Betreff: Re: [PHP-DEV] [Discussion] Last chance for case-sensitive = engine >=20 > On Wed, Feb 25, 2015 at 7:52 PM, Dmitry Stogov = wrote: >=20 > > Hi Alexander, > > > > On Tue, Feb 24, 2015 at 10:48 AM, Alexander Lisachenko < > > lisachenko.it@gmail.com> wrote: > > > > > Morning! > > > > > > I want to ask this question one more time before PHP7 feature > > > freeze: can we the engine case sensitive from PHP>=3D7.0? > > > > > > There is a draft for that: = https://wiki.php.net/rfc/case-sensitivity > > > (mostly empty), so I decided to ask this question in the internals > > > mail list. > > > > > > Pros: more simple O(1) hash table checks for properties, = functions, > > > methods, classes without strtolower normalization on the > > > engine/parser level. Consistency with unicode class names (yes, = they > > > are case > > sensitive, > > > check http://3v4l.org/ia0pc), consistency with exisiting PSR0,4 > > standards > > > (case sensitive mapping of class names to the file names) > > > > > > From my experience, all modern PHP framework don't use > > > case-insensitive code, so chance to break anything for them is = really low. > > > > > > Cons: on the extension level things aren't so good and can be some > > > BC breaks (like with phpng) > > > > > > Possible ways: > > > > > > 1) Keep PHP engine case-insensitive for PHP7 > > > 2) Make PHP engine case-sensitive since PHP7 with possible minor = BC > > breaks > > > in the extensions (this breaks can be easily fixed) > > > 3) Add a compile-time switch, eg. --with-case-sensitivity to the > > > configuration to have an ability to build PHP with sensitivity and > > > make this option enabled by default since next major version > > > (PHP>=3D8.0). Add deprecation notices in 7.x > > > > > > Thoughts? > > > > > > > I case we would designed a new language I would rise two hands. > > Changing, syntax in an existent widely used language is an = additional > > pain for users. > > Technically it shouldn't be very difficult to remove support for > > case-insensitivity, and it'll even improve speed and memory > > consumption, but I don't think it costs the compatibility break. > > > > Thanks. Dmitry. > > >=20 > I agree that doesn't seem like a reasonable idea. >=20 > Julien.P I also agree, I think that is something for a static code analyser to = rant about