Skip to content
Commit 9cfd1bd7 authored by Kevin Ryde's avatar Kevin Ryde Committed by Torsten Schönfeld
Browse files

Fix fetching default values for unichar properties of custom subclasses

In gperl_type_get_property() use g_param_value_set_default() for the pspec
default value instead of a call out to the Perl level get_default_value()
method.

Fixes Perl-implemented object $obj->get_property() of a
GParamSpecUnichar property.  Previously got a warning like "Argument
"\x{78}" isn't numeric in subroutine entry" and the wrong value due to
get_default_value() giving a string but GValue wanting a uint
codepoint.  (Both before and after the recent get_default_value()
unification changes.)

This doesn't lose any support for Perl-code subclassed ParamSpecs,
since such subclassing doesn't work properly yet.  There's no boxed
subclassing, and a mere re-blessing has never reached
gperl_type_get_property(), it sees only the C-level object, so a
different get_default_value() in a reblessing was never reached by
this gperl_type_get_property().

https://bugzilla.gnome.org/show_bug.cgi?id=567668
parent 9c587df5
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment