Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:105270 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 24808 invoked from network); 14 Apr 2019 16:54:59 -0000 Received: from unknown (HELO localhost.localdomain) (76.75.200.58) by pb1.pair.com with SMTP; 14 Apr 2019 16:54:59 -0000 To: internals@lists.php.net References: <40683e93-f8e9-5a8c-9646-31c73c99396f@fischer.name> Date: Sun, 14 Apr 2019 14:53:08 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-Posted-By: 94.0.205.114 Subject: Re: [PHP-DEV] [RFC] Permit trailing whitespace in numeric strings From: markyr@gmail.com (Mark Randall) Message-ID: A thought - In the event that explicit casting specifically does get tightened up, what will become the suggested method for making a best-effort conversion to an integer? Personally I'm in favour of explicit casts being a bit more forgiving, but in the event they're not, what will replace it as the recommended inbuilt method that handles strings with whitespace and trailing junk? Will there be one? I'm aware that the most common IDEs suggest using (int) instead of intval. -- Mark Randall