Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:106028 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 98668 invoked from network); 22 Jun 2019 15:43:51 -0000 Received: from unknown (HELO mail-lf1-f48.google.com) (209.85.167.48) by pb1.pair.com with SMTP; 22 Jun 2019 15:43:51 -0000 Received: by mail-lf1-f48.google.com with SMTP id 136so6911124lfa.8 for ; Sat, 22 Jun 2019 05:59:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ipGqwrzgojiPyuT25JIaB9cdhoLnATnNcjYACM+iVFI=; b=l1ZGVmJVNTrrGkz6r96dGu4CDR5Hupg2uTvsWlhGjXcPFI36XGhFlHWSLCr0czAL6R mDyuEDcDb0E+5XAwOUgqlMIAlq2RiG4kAr7cZ7U8/Lqg42t/QzL4Oo2Ov1LuufpWgpRl 8D7/oMUJpUpkKOOml9afwEOzRDtn06Rnt9/ZSNH3JEdNv3g0p2YeShwlwkGlT81zbLYn BnBXWriRwNF40vcwtWxpMRCyduxIibzMFVpZ4mmHl8yHa8uUUnq6WRJTUa+1yfjWWwwV boHMvFS4MuuwutqpUfotwhE3oYAqr2w0PX5Y8DhI5gG45EWwj5z/xRd35tM252ZvTXRF /MGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ipGqwrzgojiPyuT25JIaB9cdhoLnATnNcjYACM+iVFI=; b=uXMIRknE7kVmxoIUQKMVrdeG9ovJwExte4X/dZ/e6Slz/ac94C6lIvXQ2BXbZaU4nK 3wG6ayJt2hPcaPyEoclowOr75O/K1lTJlLaaPlHzUIjRJ0ymnVFN+IoGLNYOnVAD8+rH B68LNAvrPG734JgEtaac3UZD5O8Km4FJWU0/D5MSYYtm6BoKj1kZDSO2ZBL82wSh5uPs fPUlN/JCuTVbFtiuudM7nORtEPuWQCN347ELsL4rNvmXUe5CAlnZWkkIz9ukEVMqg931 ss0vippuCLiPcTdgYORTFhbuyGxp1J0qd+lcwOa0p+FevIQgd5Kt+6EhRWv/t2ffrHmc U9Fw== X-Gm-Message-State: APjAAAVerf8wwqEj7W7+SYP2NGOMAJfXnn1iUHrJcbgLBfhSSFLTvOZ6 XCH8ZLpt1OzrcrQmHTF1MVe1zUJRz672KXRBdaU= X-Google-Smtp-Source: APXvYqwvCSElajk+bNr0ZrAW8ix6PPZc6I+iQ1dyqwwqlffq/dwV8vyDXdcNDVIHEDVYlEuhyCqAeL/9ibgNk6Vxoz8= X-Received: by 2002:ac2:43b7:: with SMTP id t23mr22291103lfl.110.1561208354687; Sat, 22 Jun 2019 05:59:14 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Sat, 22 Jun 2019 14:58:58 +0200 Message-ID: To: Andrey Andreev Cc: Kalle Sommer Nielsen , Internals Content-Type: multipart/alternative; boundary="00000000000066d12a058be92522" Subject: Re: [PHP-DEV] [RFC] Deprecations for 7.4 From: nikita.ppv@gmail.com (Nikita Popov) --00000000000066d12a058be92522 Content-Type: text/plain; charset="UTF-8" On Sat, Jun 22, 2019 at 2:24 PM Andrey Andreev wrote: > Hi, > > With regards to the array_key_exists() deprecation, the RFC currently > says nothing about things like ArrayAccess and object properties that > contain arrays. I'm sure that these are exceptions that aren't meant > to be deprecated, but can you please specify that explicitly? We all > know how little bits like that can result in awful outcomes. > Thanks for bringing this up: It's a great example of why this needs to be deprecated. array_key_exists() actually has no support for ArrayAccess objects at all -- it only operates on (mangled) object properties. But just seeing the name and the fact that it doesn't error when passed an ArrayAccess object, it's quite easy to jump to the wrong conclusion. I've updated the RFC to mention this now. I don't understand what you mean by "object properties that contain arrays" though, or rather how that related to array_key_exists(). Also, it's unclear to me why get_called_class() should be deprecated. > While the rest of the listed deprecations have either motivation > written for them or are self-evidently legacy functionalities that > nobody should be using today, this one seems to be just a case of > "let's not have more than one way of doing things" and I'm not really > a fan of that. > Personally I agree. I don't really see a strong motivation for dropping this function. Kalle? Nikita --00000000000066d12a058be92522--