Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:104760 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 92139 invoked from network); 15 Mar 2019 21:33:02 -0000 Received: from unknown (HELO mail-ot1-f67.google.com) (209.85.210.67) by pb1.pair.com with SMTP; 15 Mar 2019 21:33:02 -0000 Received: by mail-ot1-f67.google.com with SMTP id h7so1238634otm.2 for ; Fri, 15 Mar 2019 11:23:44 -0700 (PDT) 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=kTxu52cmBVUjjUTzXdYJ8BKvs1S/ODJaSge2pJ++BSw=; b=WJrXTSGRWOhzSDuBga/hcQVMUmuHJ120Dz8dEhUylDRi75RMzWObOUSgIb0PmVL5K3 zQZdQZvEU4APNW2RTmKJTmQ9WEDsHOQGq+9vhUTiN4iYUMF+KKbEmJRoYqR56tzUxnXJ EhoV98uMinzTk0L/18bBGZLOGURrOPINg7fd2cO8x87OkpGtVkezXVAIdbqXKwlKvQd6 2ZeLir38GYo40zDZBfjDdGq5sBYXugraj5Paa0jS/rlghuYwRsKL8WLzPV0HxJyQmTbL jNLw7DN4jEjReMtiNXSybBWIXpAXWtkZxfrDcJEXdzAdQX4P5WciF+h+5Cb1aDvB0jUf vmug== X-Gm-Message-State: APjAAAW0QtXT/dzSlBrS+w8TqJxYrK23UBr+b2RYpB03/ZdsG97hgENd 42P1QmfXbLJgxwzt8HbQZk6oSxC+cEHi+/Uzfao= X-Google-Smtp-Source: APXvYqxevDtpsyPNqxST6oSViufP/y9mu+jsjoua3oI3vPRmNnaHMGBHGX0WSVkPcAxwfbxkrFhELJdxOVx+VkC4ZVM= X-Received: by 2002:a9d:58c6:: with SMTP id s6mr3104872oth.122.1552674223798; Fri, 15 Mar 2019 11:23:43 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Fri, 15 Mar 2019 20:23:32 +0200 Message-ID: To: Levi Morrison Cc: Nikita Popov , Andrey O Gromov , PHP internals Content-Type: text/plain; charset="UTF-8" Subject: Re: [PHP-DEV] Proposal for deprecate alternate syntax(curly braces) for array and string access From: kalle@php.net (Kalle Sommer Nielsen) Den fre. 15. mar. 2019 kl. 19.53 skrev Levi Morrison : > Four thoughts: > > 1. I cannot think of *any* reason to separate them. If you want to > make sure you are indexing a string, *do a type check*, not bake `{}` > into only working on strings. > 2. While Kalle says pretty much every codebase they've seen lately > has used `{}` for indexing, I have *never* seen a codebase that used > it. Well maybe that happens to be just me, not a huge amount of usages but there is usually some. > 3. In any case, usage of `{}` can be migrated to `[]` by a style > fixer, right? > 4. Even if we deprecate `{}`, I don't think we'd be in any hurry to > remove it, though with an automatic fixer this seems doable, if we > care to do it at all. The thing is, I just don't understand the rationale to remove this feature, what the full gain from doing so is? -- regards, Kalle Sommer Nielsen kalle@php.net