Re: [RFC] Glib::filename_(to|from)_unicode => Glib->filename_(to|from)_unicode?



On Tue, Dec 23, 2003 at 01:30:20PM -0500, muppet <scott asofyet org> wrote:
Two functions in Glib, added right before 1.020, do not follow the
calling conventions of just about every other function in Gtk2-Perl.

  string = Glib::filename_to_unicode string
  string = Glib::filename_from_unicode string

These require that you use a fully-qualified name for the functions,
rather than allowing class parameters (the arrow syntax).  These
*should* be callable as

  string = Glib->filename_to_unicode(string)
  string = Glib->filename_from_unicode(string)

I started to change the XS code to allow both calling conventions (and
thus fix the bug quietly), but ran into a snag -- there are PROTOTYPE
declarations on the xsubs.  Therefore, changing this will necessarily

That would be a bug and totally against design principles used in perl
_and_ Gtk2, since it:

- is totally unlike any other perl module, it's unperlish
- it is totally unlike the C syntax, and changing the API is
  not a goal of gtk2-perl, now is it?
- it's unneeccary slow
- disallows compile-time-checking (a great minus of the gtk2 API
  over gtk1, don't increase this problem needlessly)
- it's confusing to users
- it's awkward to use

Comments, arguments, i need them all asap.

Sorry, sitting in an airplane right now without internet access. But
changing this would be a great sin.

-- 
      -----==-                                             |
      ----==-- _                                           |
      ---==---(_)__  __ ____  __       Marc Lehmann      +--
      --==---/ / _ \/ // /\ \/ /       pcg goof com      |e|
      -=====/_/_//_/\_,_/ /_/\_\       XX11-RIPE         --+
    The choice of a GNU generation                       |
                                                         |



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