UG(ascii_conv) is for the format string, not the arguments. The warning
is thrown by this code:
convert_to_string_ex(argv[currentarg]);
It should check the arg type and return with a warning if it's Unicode.
-Andrei
Steph Fox wrote:
It does - 'UG(ascii_conv)' - but sometimes there's a unicode-to-binary
conversion warning thrown by that, and then you have to cast the
variable to a binary empty string to suppress the warning before you
assign the pack() result to it. (See ext/phar/tests/phar_test.inc.)
There are similar issues with unpack(), and with fwrite()/fread() and
friends when dealing with a purely binary string.
What concerns me at this point is that we could and should be telling
PHP users how to future-proof their code during the move from PHP 4 to
PHP 5. If we can get a fix on that now and get word out, we'll have made
their future migration path *much* smoother.
- Steph
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php