Wx and AnyEvent on perl 5.16: failure on locales with comma as decimal separator

Olivier Mengué dolmen at cpan.org
Fri Jun 26 10:44:51 CEST 2015


Hi,

This is just to advertise an issue I discovered in Wx on perl 5.16.3.
https://rt.cpan.org/Ticket/Display.html?id=105461
On (at least) this perl (I have not been able to reproduce on 5.18.2),
$Wx::VERSION may contain a comma instead of a dot if the locale
(LC_NUMERIC, LC_ALL) use a comma as the decimal separator. This is in
particular the case with fr_FR.UTF-8.

As AnyEvent rightfully uses $Wx::VERSION in numeric context (AnyEvent.pm
7.09 line 1446) when selecting its model, a failure occurs and AnyEvent is
not properly loaded (the missing ROUNDUP constant is just the canary: the
issue that is visible in real code at runtime when the event loop runs).

$ LC_NUMERIC=fr_FR.UTF-8 perl -MWx -MAnyEvent::Loop -E 'say
AnyEvent::Loop::ROUNDUP'
Undefined subroutine &AnyEvent::Loop::ROUNDUP called at -e line 1.

Olivier Mengué.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.schmorp.de/pipermail/anyevent/attachments/20150626/4be0cb10/attachment.html>


More information about the anyevent mailing list