Re: g_strerror




On May 13, 2008, at 8:38 PM, Kevin Ryde wrote:

I want to put $! into some gtk displayed strings, and if I'm not mistaken it's locale charset bytes. I know how to decode, but I wondered if g_strerror could be offered, on the principle "why can't someone else do it".

The reason we never bound that before is the Glib module's idea of "don't bind stuff that perl already does".

Honestly, i'd never considered the charset issue with $!.

So, the proposed API (bound as functions) would be:

    my $error_description = Glib::strerror ($!);
    my $signal_description = Glib::strsignal ($signo);

which are basically easier to remember than the equivalent Encode incantations.

Anybody have any objections?



--
One, two, free, four, five, six, sebben, eight, nine, ten, elebben, twull, fourteen, sickteen, sebbenteen, eightteen, elebbenteen, fiffeen, elebbenteen!
  -- Zella, aged three, counting to twenty.





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]