And what actually failed? The idea seams straightforward. Robert
2011/6/20 Johannes Schlüter <johan...@schlueters.de> > On Mon, 2011-06-20 at 20:38 +0200, Robert Eisele wrote: > > I really like the ideas shared here. It's a thing of consideration that > > array-functions should also work with strings. Maybe this would be the > way > > to go, but I'm more excited about the OOP implementation of TextIterator > and > > ByteIterator, which solves the whole problem at once (and is easier to > > implement, as mentioned by Stas). As Jonathan said, Database results > with a > > certain encoding could get iterated, too. The only way to workaround the > > Text/Byte problem would be, offsetting >EVERY< string with 1-2 byte > > "string-type" information or an additional type flag in the > zval-strcuture. > > Handling everything with zval's instead of objects would have the > advantage, > > that database-layers like mysqlnd could write the database-encoding > directly > > into the zval and the user had no need to decide what encoding is used. > > Welcome back to the failed PHP 6 Unicode project. ;-) > (while we didn't store the original encoding but converted to Utf-16, > which prevents random/strange conversions in other places when mixing > encodings) > > johannes > > >