Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:18734 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 10798 invoked by uid 1010); 9 Sep 2005 07:02:22 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 10782 invoked from network); 9 Sep 2005 07:02:22 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 9 Sep 2005 07:02:22 -0000 X-Host-Fingerprint: 82.94.239.5 jdi.jdi-ict.nl Linux 2.5 (sometimes 2.4) (4) Received: from ([82.94.239.5:45887] helo=jdi.jdi-ict.nl) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id 0B/E2-17383-C7331234 for ; Fri, 09 Sep 2005 03:02:21 -0400 Received: from localhost (localhost [127.0.0.1]) by jdi.jdi-ict.nl (8.12.11/8.12.11) with ESMTP id j8972HG7014086; Fri, 9 Sep 2005 09:02:17 +0200 Received: from localhost (localhost [127.0.0.1]) by jdi.jdi-ict.nl (8.12.11/8.12.11) with ESMTP id j8972Fq3014075; Fri, 9 Sep 2005 09:02:16 +0200 Date: Fri, 9 Sep 2005 09:02:14 +0200 (CEST) X-X-Sender: derick@localhost To: Ilia Alshanetsky cc: PHP Developers Mailing List In-Reply-To: <4320AB2B.6020109@prohost.org> Message-ID: References: <4320AB2B.6020109@prohost.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by amavisd-new at jdi-ict.nl Subject: Re: [PHP-DEV] ord() on binary strings From: derick@php.net (Derick Rethans) On Thu, 8 Sep 2005, Ilia Alshanetsky wrote: > It makes perfect sense to me that ord() would work on binary strings. > When we return an ASCII value we don't limit the range returned, it can > be 1 or 255. So, I see no reason to cripple this function and prevent it > from working on binary data. Indeed, the only thing is that you can't really talk about "ASCII" values, as binary data doesn't really have an encoding (and certainly not ascii as that's 7bits only). But IMO that's something to tune in the docs. Derick -- Derick Rethans http://derickrethans.nl | http://ez.no | http://xdebug.org