Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:83878 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 63170 invoked from network); 26 Feb 2015 09:27:36 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 26 Feb 2015 09:27:36 -0000 Authentication-Results: pb1.pair.com smtp.mail=julienpauli@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=julienpauli@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.212.174 as permitted sender) X-PHP-List-Original-Sender: julienpauli@gmail.com X-Host-Fingerprint: 209.85.212.174 mail-wi0-f174.google.com Received: from [209.85.212.174] ([209.85.212.174:59082] helo=mail-wi0-f174.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id AD/92-47686-507EEE45 for ; Thu, 26 Feb 2015 04:27:34 -0500 Received: by mail-wi0-f174.google.com with SMTP id em10so39429699wid.1 for ; Thu, 26 Feb 2015 01:27:30 -0800 (PST) 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:message-id :subject:to:cc:content-type; bh=j8WjwKivsauJi3l9stX3VTnuiLzpvKnL349NbidedTs=; b=eIhMi2Ok51cZiQjHFoZAHZRGFFgwURnpVonBPt0bZxfgzXb9SwfDwvU8kF9GLMBpyx hx/Sb8ybUGKOzSRuj4WVcRS9umsuurZ/9Quokz2zGINE1ivFVMgD+TKQIIUtHEYMINdT M17J4gc1ImjdW2gQf2OB8ELLjm4uPDaRCXDf1xjmxTA3kPMlOYZePKz2dH8bGMsrVs4C WjT35am6A+2nXuZHtwjsl3L90fWVHLjeOTR+ISDNVJRdz0SeIv/QHlY9OI5Mfnn3EieC X1cXV4CrdiLHWuf0Yi4q0Up1IkSLvC2elmTBN0ofFeJly+i5hUSanRZn5J98viB7+ZAI OUsg== X-Received: by 10.194.201.7 with SMTP id jw7mr4919572wjc.2.1424942850162; Thu, 26 Feb 2015 01:27:30 -0800 (PST) MIME-Version: 1.0 Sender: julienpauli@gmail.com Received: by 10.194.198.210 with HTTP; Thu, 26 Feb 2015 01:26:49 -0800 (PST) In-Reply-To: References: Date: Thu, 26 Feb 2015 10:26:49 +0100 X-Google-Sender-Auth: wnm95gWvPDQiYHoeynocVTDsL9s Message-ID: To: Dmitry Stogov Cc: Alexander Lisachenko , PHP internals list Content-Type: multipart/alternative; boundary=047d7b873ab068c6e0050ffa5cb2 Subject: Re: [PHP-DEV] [Discussion] Last chance for case-sensitive engine From: jpauli@php.net (Julien Pauli) --047d7b873ab068c6e0050ffa5cb2 Content-Type: text/plain; charset=UTF-8 On Wed, Feb 25, 2015 at 7:52 PM, Dmitry Stogov wrote: > 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>=7.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>=8.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. > I agree that doesn't seem like a reasonable idea. Julien.P --047d7b873ab068c6e0050ffa5cb2--